/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * com_distri_folios_agregar.java
 *
 * Created on 26/12/2011, 06:34:04 PM
 */

package sie_invdis;


import java.sql.*;
import javax.swing.*;
import java.awt.*;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Calendar;
import java.text.*;
import java.text.ParseException;
import org.jfree.ui.RefineryUtilities;
/**
 *
 * @author Michelle
 */
public class com_distri_folios_agregar extends javax.swing.JFrame {

private javax.swing.table.DefaultTableModel jtable_modelo_doctomovidet;
private javax.swing.table.DefaultTableModel jtable_modelo_cliente;
private javax.swing.table.DefaultTableModel jtable_modelo_almacen;
private javax.swing.table.DefaultTableModel jtable_modelo_almacenexterno;
private javax.swing.table.DefaultTableModel jtable_modelo_almacenexternodif;

    private ResultSet rs = null;
    private bd_conexion x = new bd_conexion();
    private int buscamp=2,controlcomboinsu=0,opbuscamp=2,control_enter=0,yacarguecatdocto=0,indexactual=0,listap=1,opcioncatalogo=3, buscampalma=1,controlcombocambio=0;
    private SimpleDateFormat formateadoresta = new SimpleDateFormat("yyyy-MM-dd");
    private SimpleDateFormat formateador = new SimpleDateFormat("dd-MM-yyyy");
    /** Creates new form com_distri_folios_agregar */
    public com_distri_folios_agregar() {
        this.iniciar_modelo_doctodetalle();
        this.iniciar_modelo_cliente();
        this.iniciar_modelo_de_tabla_almacen();
        this.iniciar_modelo_almacenexterno();
        this.iniciar_modelo_almacenexternodif();
        initComponents();
        this.loadcomalmacenes();
        this.loadcombolineaarticulo();
        this.loadcombomonedas();
        controlcombocambio=1;
        java.util.Date fechahoya=new Date();
        this.jdc_fechadocto.setDate(fechahoya);
        this.buttonGroup1.setSelected(jrbtn_precio1.getModel(), true);
        this.buttonGroup2.setSelected(jrb_bdescrip.getModel(), true);
        this.buttonGroup3.setSelected(jrb_bclave1.getModel(), true);
        jtb_insumos.getColumnModel().getColumn(0).setPreferredWidth(60);//status
        jtb_insumos.getColumnModel().getColumn(1).setPreferredWidth(160);//Folio
        jtb_insumos.getColumnModel().getColumn(2).setPreferredWidth(50);//status
        jtb_insumos.getColumnModel().getColumn(3).setPreferredWidth(20);//doc ant.
        jtb_insumos.getColumnModel().getColumn(4).setPreferredWidth(20);//fecha
        jtb_insumos.getColumnModel().getColumn(5).setPreferredWidth(20);//fecha llega tienda
        jtb_insumos.getColumnModel().getColumn(6).setPreferredWidth(20);//f.recepcion
        jtb_insumos.getColumnModel().getColumn(7).setPreferredWidth(20);//f.recepcion
        jtb_insumos.getColumnModel().getColumn(8).setPreferredWidth(20);//f.recepcion
        jtb_insumos.getColumnModel().getColumn(9).setPreferredWidth(20);//f.recepcion

        
        jt_clientes.getColumnModel().getColumn(0).setPreferredWidth(50);//status
        jt_clientes.getColumnModel().getColumn(1).setPreferredWidth(60);//clasif
        jt_clientes.getColumnModel().getColumn(2).setPreferredWidth(120);//provee
        jt_clientes.getColumnModel().getColumn(3).setPreferredWidth(80);//direccion
        jt_clientes.getColumnModel().getColumn(4).setPreferredWidth(80);//poblacion
        jt_clientes.getColumnModel().getColumn(5).setPreferredWidth(60);//telefono
        jt_clientes.getColumnModel().getColumn(6).setPreferredWidth(60);//ultima compra
        jt_clientes.getColumnModel().getColumn(7).setPreferredWidth(120);//Direccion2
        jt_clientes.getColumnModel().getColumn(8).setPreferredWidth(60);//observ

    jtb_almacen_control.getColumnModel().getColumn(0).setPreferredWidth(60);//familia
    jtb_almacen_control.getColumnModel().getColumn(1).setPreferredWidth(120);//subfam.
    jtb_almacen_control.getColumnModel().getColumn(2).setPreferredWidth(15);//clave
    jtb_almacen_control.getColumnModel().getColumn(3).setPreferredWidth(15);//descrip.
    jtb_almacen_control.getColumnModel().getColumn(4).setPreferredWidth(15);//descrip.
    jtb_almacen_control.getColumnModel().getColumn(5).setPreferredWidth(15);//descrip.
      this.jtf_idarticulo.requestFocus();

    this.jPanel9.setVisible(false);
    }

private void iniciar_modelo_cliente()
    {
        jtable_modelo_cliente=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_cliente.addColumn("<html><b>Status</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Clasif.</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Cliente</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Direccion</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Poblacion</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Telefono</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>C.p.</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Dir Entrega</b></html>");
        jtable_modelo_cliente.addColumn("<html><b>Observ.</b></html>");
    }
private void iniciar_modelo_doctodetalle()
    {
        jtable_modelo_doctomovidet=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_doctomovidet.addColumn("<html><b>Clave</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Descripcion</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Item</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Unidad</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Cantidad</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Precio</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>%desc</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>%Imp.</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Importe</b></html>");
        jtable_modelo_doctomovidet.addColumn("<html><b>Obser.</b></html>");
    }


private void iniciar_modelo_almacenexterno()
    {
        jtable_modelo_almacenexterno=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_almacenexterno.addColumn("<html><b>clave</b></html>");
        jtable_modelo_almacenexterno.addColumn("<html><b>Descripcion</b></html>");
        jtable_modelo_almacenexterno.addColumn("<html><b>Precio</b></html>");
        jtable_modelo_almacenexterno.addColumn("<html><b>Exist. Local</b></html>");
        jtable_modelo_almacenexterno.addColumn("<html><b>Exist. Servidor</b></html>");
        jtable_modelo_almacenexterno.addColumn("<html><b>Diferencia</b></html>");
    }
private void iniciar_modelo_almacenexternodif()
    {
        jtable_modelo_almacenexternodif=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_almacenexternodif.addColumn("<html><b>clave</b></html>");
        jtable_modelo_almacenexternodif.addColumn("<html><b>Exist. Local</b></html>");
        jtable_modelo_almacenexternodif.addColumn("<html><b>Exist. Servidor</b></html>");
        jtable_modelo_almacenexternodif.addColumn("<html><b>Diferencia</b></html>");
    }
private void loadcomalmacenes()
    {
        try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_almacenes() as (id smallint,cla character varying(30));",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcmbx_almacenes.addItem(rs.getString("id")+":"+rs.getString("cla"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
private void loadcombolineaarticulo(){

this.jcbx_linea.addItem("-1:Todos");
            try
            {
               rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_lineas() as (id smallint,describe text);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_linea.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
private void loadcombomonedas()
    {
    DecimalFormat miformat = new DecimalFormat("############.##");
        try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_ventas_monedas(0,0,'','') as (id smallint,descrip character varying(30),cambioactu numeric,fechaactua date);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_idmoneda.addItem(rs.getString("id")+":"+rs.getString("descrip")+":"+miformat.format(rs.getFloat("cambioactu")));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
/*
private void loadclientes()
    {
          this.jcmbx_idcliente.addItem("0:Elegir Cliente");
          try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_ventas_clientes_catalogo(1,'','') as (id character varying(12),descrip character varying(60));",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcmbx_idcliente.addItem(rs.getString("id")+":"+rs.getString("descrip"));
                    }
             }
            catch(Exception e)
                {
                    System.out.println(e.getMessage());
                }
    }
*/
private void iniciar_modelo_de_tabla_almacen()
    {
        jtable_modelo_almacen=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_almacen.addColumn("Clave");
        jtable_modelo_almacen.addColumn("Descripcion.");
        jtable_modelo_almacen.addColumn("Precio");
        jtable_modelo_almacen.addColumn("P.may");
        jtable_modelo_almacen.addColumn("Existencia");
        jtable_modelo_almacen.addColumn("E.mv");
        //se crea intancia de la clase conexion

}
private void carga_datos_catalogo(int opcion, int opbuscamp,String busqueda,int almacen,String cantidad,String observa)
 {
       DecimalFormat miformat = new DecimalFormat("###,###,###,###.##");
       Object[] fnewRow = new Object[10];
       int encontro=0;
       String texto="select * from x1distribucion_terminados_articulos_catalogo("+opcion+","+opbuscamp+",'"+busqueda+"') as (id character varying(16),idstatus smallint,statusdescribe text,describearticulo character varying(80),describcorta character varying(20),unsal character varying(3),unent character varying(3),facentruni numeric,uniempaque character varying(12),idtempo smallint,describetemp text,idfamilia character varying(5),familiadescribe character varying(35),controlalma character varying(20),stocminimo numeric,stocmaximo numeric,precio1 numeric,precio2 numeric,precio3 numeric,precio4 numeric,precio5 numeric,ultimocosto numeric,costoprom numeric,pensurtir numeric,tiemposurtido smallint,acumprod numeric,acumimporte numeric,idtipoarticulo smallint,tipodescribe text,fechaprototipo date,fechaautoriza date,fechainiprod date,fechaultimaent date,usuario character varying(20),observacion character varying(255),idprovee character varying(12),nombrecreador character varying(80),valor_x character varying(20),valorx_st character varying(20),idpersonal character varying(16),nombrepersonal character varying(80),descripprovee character varying(60),existencia numeric)";
       System.out.println(texto);
       try
        {
           rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                    encontro=1;
                    fnewRow[0]=rs.getString("id");
                    fnewRow[1]=rs.getString("describearticulo");
                    fnewRow[2]=rs.getString("valor_x");
                    fnewRow[3]=rs.getString("unsal");
                    fnewRow[4]=cantidad;
                    switch (listap) {
                        case 1:
                            fnewRow[5]=miformat.format(rs.getFloat("precio5"));
                        break;
                        case 2:
                            fnewRow[5]=miformat.format(rs.getFloat("precio2"));
                        break;
                    }
                    fnewRow[6]=this.jtf_descuento.getText();
                    fnewRow[7]=this.jtf_impuesto.getText();
                    fnewRow[8]="0";
                    fnewRow[9]=observa;
                    jtable_modelo_doctomovidet.addRow(fnewRow);
                    this.jtf_ultimocodigo.setText(rs.getString("id"));
                    this.jtf_ultimodescripcion.setText(rs.getString("describearticulo"));
                    this.jep_articuloimagen.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+rs.getString ("id")+".JPG\" width=\"180\" height=\"160\" border=\"0\" alt=\"Foto Articulo\"></img>");
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
           if(encontro==0)
                {
                    JOptionPane.showMessageDialog(null,"Clave:"+busqueda+" No Encontrado", "Sistema Integral(Agregar Articulo) : Ayuda",1);
                }
       this.calcularimportes();
       this.jtf_idarticulo.setText("");

  }
 private void calcularimportes()
    {
      DecimalFormat miformat = new DecimalFormat("############.##");
     int numerofilas=this.jtable_modelo_doctomovidet.getRowCount(),error=0;
    String punto="",comas="",imagen="",cambio[]=null;
    float cantidad=0,costo=0,importefila=0,descuento=0,impuesto=0,doctosubtotal=0,doctoimpuesto=0,doctodescuento=0,doctototal=0,piezasindi=0;
     for(int i = 0 ;i < numerofilas; i++)
                {
                 try
                       {
                            cantidad = Float.valueOf(this.jtb_insumos.getValueAt(i, 4).toString()).floatValue();
                            costo = Float.valueOf(this.jtb_insumos.getValueAt(i, 5).toString()).floatValue();
                            piezasindi+=cantidad;
                            descuento=(costo*cantidad)*(Float.valueOf(this.jtb_insumos.getValueAt(i, 6).toString())/100);
                            System.out.println(descuento);
                            impuesto=Float.valueOf(this.jtf_impuesto.getText().toString())/100;
                            System.out.println(descuento+":"+impuesto);
                            importefila=(cantidad*costo);
                            doctodescuento+=descuento;
                            doctosubtotal+=importefila;

                        }
                            catch (NumberFormatException nfe) {
                            cantidad=0;
                            costo=0;
                            error=1;
                        }
                      jtable_modelo_doctomovidet.setValueAt(miformat.format(importefila), i,8);
                }
    doctoimpuesto=(doctosubtotal-doctodescuento)*impuesto;
    doctototal=(doctosubtotal-doctodescuento)+doctoimpuesto;
    this.jtf_doctosubtotal.setText(miformat.format(doctosubtotal));
    this.jtf_doctodesc.setText(miformat.format(doctodescuento));
    this.jtf_doctoimp.setText(miformat.format(doctoimpuesto));
    this.jtf_doctototal.setText(miformat.format(doctototal));
    this.jtf_totalpiezas.setText(miformat.format(piezasindi));
     this.jtf_doctototal1.setText(miformat.format(doctototal));
    this.jtf_totalpiezas1.setText(miformat.format(piezasindi));
    if(doctototal>0)
    {
        cambio=this.jcbx_idmoneda.getSelectedItem().toString().split(":");
        this.jlbl_monedadescribe.setText("Mon."+cambio[1]);
        this.jtf_conversionmoneda.setText(miformat.format(doctototal/Float.valueOf(this.jtf_tipocambio.getText().toString())));
    }
    

    }

 private void carga_datos_clientes(int opcion,String textobusca)
    {
       //invoco al metodo que trae el recordset de datos
       //voy por el detalle del documento
       while(jtable_modelo_cliente.getRowCount()>0)jtable_modelo_cliente.removeRow(0);
       Object[] fnewRow = new Object[9];
       String texto="select * from x1distribucion_terminados_ventas_clientes_catalogo("+opcion+",'"+textobusca+"','') as (id character varying(12),nombre character varying(60),direccion character varying(50),colonia character varying(50),poblacion character varying(40),cpcliente character varying(6),rfc character varying(15),curp character varying(20),telefono character varying(80),fax character varying(15),email character varying(80),clasif smallint,diascre smallint,limite numeric,descliente numeric,fechaultv date,fechaultp date,obser character varying(80),idstatus smallint,direccion2 character varying(80),statusdes character varying(40),descripcla character varying(40),atnven character varying(60),atncob character varying(60),acumcli numeric,idreg integer);";
       System.out.println(texto);
       try
       {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                        fnewRow[0]=rs.getString("idstatus")+":"+rs.getString("statusdes");
                        fnewRow[1]=rs.getString("clasif")+":"+rs.getString("descripcla");
                        fnewRow[2]=rs.getString("id")+":"+rs.getString("nombre");
                        fnewRow[3]=rs.getString("direccion")+" "+rs.getString("colonia");
                        fnewRow[4]=rs.getString("poblacion");
                        fnewRow[5]=rs.getString("telefono")+" "+rs.getString("email");
                        /*
                         if (rs.getString("fechaultv")!= null)
                                {
                                    fnewRow[6]=this.fechaeuropea(rs.getString("fechaultv"));
                                }
                         * */
                         fnewRow[6]=rs.getString("cpcliente");
                        fnewRow[7]=rs.getString("direccion2");
                        fnewRow[8]=rs.getString("obser");
                        jtable_modelo_cliente.addRow(fnewRow);
                }
        }
        catch(Exception e)
            {
            System.out.println(e.getMessage());
            }

     this.jlbl_cantidadregistros.setText(String.valueOf(this.jtable_modelo_cliente.getRowCount()));
     this.jlbl_textobuscado.setText(this.jtf_busqueda.getText().toUpperCase().trim());
   }

 private void carga_datos_catalogoarticulos_almacen(int rbbuscam,int rbopbuscam,String busqueda)
 {
     DecimalFormat miformat = new DecimalFormat("###,###,###,###.##");
     String arreglo_linea[]=this.jcbx_linea.getSelectedItem().toString().split(":");

     int fila=0,linea=0;
     while(jtable_modelo_almacen.getRowCount()>0)jtable_modelo_almacen.removeRow(0);
     String texto="select * from x1distribucion_terminados_articulos_catalogov2("+rbbuscam+","+rbopbuscam+",'"+busqueda+"') as (id character varying(16),codbarra character varying(16),idstatus smallint,statusdescribe text,describearticulo character varying(80),describcorta character varying(20),unsal character varying(3),unent character varying(3),facentruni numeric,uniempaque character varying(12),idtempo smallint,describetemp text,idfamilia character varying(5),familiadescribe character varying(40),controlalma character varying(20),stocminimo numeric,stocmaximo numeric,precio1 numeric,precio2 numeric,precio3 numeric,precio4 numeric,precio5 numeric,ultimocosto numeric,costoprom numeric,pensurtir numeric,tiemposurtido smallint,acumprod numeric,acumimporte numeric,idtipoarticulo smallint,tipodescribe text,fechaprototipo date,fechaautoriza date,fechainiprod date,fechaultimaent date,usuario character varying(20),observacion character varying(255),idprovee character varying(12),descripprovee character varying(60),nombrecreador character varying(80),valor_x character varying(20),valorx_st character varying(20),idpersonal character varying(16),nombrepersonal character varying(80),idlinea smallint,describelinea text,existenciaf numeric,almacenlugar text,existencia numeric)";
     System.out.println(texto);
     linea=Integer.valueOf(arreglo_linea[0]);
     try
        {
        rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                    {
                        if (linea<0)
                             {
                                jtable_modelo_almacen.addRow(new Object[]{rs.getString ("id"),rs.getString ("describearticulo"),"$"+miformat.format(rs.getFloat("precio5")),"$"+miformat.format(rs.getFloat("precio2")),rs.getString ("existencia"),rs.getString ("stocminimo")});
                            }
                        else
                             {
                                if (arreglo_linea[0].equals(rs.getString ("idlinea")))
                                    {
                                        jtable_modelo_almacen.addRow(new Object[]{rs.getString ("id"),rs.getString ("describearticulo"),"$"+miformat.format(rs.getFloat("precio5")),"$"+miformat.format(rs.getFloat("precio2")),rs.getString ("existencia"),rs.getString ("stocminimo")});
                                    }
                            }
                    }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }

 }
 private void carga_datos_catalogoarticulos_actualizar(int rbbuscam,int rbopbuscam,String busqueda)
 {
     DecimalFormat miformat = new DecimalFormat("###,###,###,###.##");
     String arreglo_linea[]=this.jcbx_linea.getSelectedItem().toString().split(":");

     int fila=0,linea=0;
     while(jtable_modelo_almacenexterno.getRowCount()>0)jtable_modelo_almacenexterno.removeRow(0);
     String texto="select * from x1distribucion_terminados_articulos_catalogov2("+rbbuscam+","+rbopbuscam+",'"+busqueda+"') as (id character varying(16),codbarra character varying(16),idstatus smallint,statusdescribe text,describearticulo character varying(80),describcorta character varying(20),unsal character varying(3),unent character varying(3),facentruni numeric,uniempaque character varying(12),idtempo smallint,describetemp text,idfamilia character varying(5),familiadescribe character varying(40),controlalma character varying(20),stocminimo numeric,stocmaximo numeric,precio1 numeric,precio2 numeric,precio3 numeric,precio4 numeric,precio5 numeric,ultimocosto numeric,costoprom numeric,pensurtir numeric,tiemposurtido smallint,acumprod numeric,acumimporte numeric,idtipoarticulo smallint,tipodescribe text,fechaprototipo date,fechaautoriza date,fechainiprod date,fechaultimaent date,usuario character varying(20),observacion character varying(255),idprovee character varying(12),descripprovee character varying(60),nombrecreador character varying(80),valor_x character varying(20),valorx_st character varying(20),idpersonal character varying(16),nombrepersonal character varying(80),idlinea smallint,describelinea text,existenciaf numeric,almacenlugar text,existencia numeric)";
     System.out.println(texto);
     linea=Integer.valueOf(arreglo_linea[0]);
     try
        {
        rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                    {
                    if ((rs.getInt("idlinea")==1) && (rs.getString("existencia")!=null))
                             {
                                 //jtable_modelo_almacenexterno.addRow(new Object[]{rs.getString ("id"),rs.getString ("describearticulo"),""+miformat.format(rs.getFloat("precio2")),rs.getString ("existencia"),"0"});
                                jtable_modelo_almacenexterno.addRow(new Object[]{rs.getString ("id"),rs.getString ("describearticulo"),""+miformat.format(rs.getFloat("precio2")),rs.getString ("existencia"),"0"});
                             }

                    }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }

 }
  private void carga_datos_clientesactualiza(int opcion,String textobusca)
    {
       String texto="select * from x1distribucion_terminados_ventas_clientes_catalogo("+opcion+",'"+textobusca+"','') as (id character varying(12),nombre character varying(60),direccion character varying(50),colonia character varying(50),poblacion character varying(40),cpcliente character varying(6),rfc character varying(15),curp character varying(20),telefono character varying(80),fax character varying(15),email character varying(80),clasif smallint,diascre smallint,limite numeric,descliente numeric,fechaultv date,fechaultp date,obser character varying(80),idstatus smallint,direccion2 character varying(80),statusdes character varying(40),descripcla character varying(40),atnven character varying(60),atncob character varying(60),acumcli numeric,idreg integer);";
       System.out.println(texto);
       try
       {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                       this.jtf_idcliente1.setText(rs.getString("id"));
                       this.jtf_cliente.setText(rs.getString("nombre"));
                       this.jtf_domcalle1.setText(rs.getString("direccion"));
                       this.jtf_domcolonia1.setText(rs.getString("colonia"));
                       this.jtf_dompobla1.setText(rs.getString("poblacion"));
                       this.jtf_email2.setText(rs.getString("email"));
                       this.jtf_cp.setText(rs.getString("cpcliente"));
                       this.jtf_rfc.setText(rs.getString("rfc"));
                       this.jtf_tel.setText(rs.getString("telefono"));
                       this.jtf_direccion2.setText(rs.getString("direccion2"));
                       this.jtf_atnventas.setText(rs.getString("atnven"));
                       this.jtf_atncobra.setText(rs.getString("atncob"));
                       this.jtf_observaciones1.setText(rs.getString("obser"));
                }
        }
        catch(Exception e)
            {
            System.out.println(e.getMessage());
            }
   }
  private void carga_datos_clientedocto(int opcion,String textobusca)
    {
       String texto="select * from x1distribucion_terminados_ventas_clientes_catalogo("+opcion+",'"+textobusca+"','') as (id character varying(12),nombre character varying(60),direccion character varying(50),colonia character varying(50),poblacion character varying(40),cpcliente character varying(6),rfc character varying(15),curp character varying(20),telefono character varying(80),fax character varying(15),email character varying(80),clasif smallint,diascre smallint,limite numeric,descliente numeric,fechaultv date,fechaultp date,obser character varying(80),idstatus smallint,direccion2 character varying(80),statusdes character varying(40),descripcla character varying(40),atnven character varying(60),atncob character varying(60),acumcli numeric,idreg integer);";
       System.out.println(texto);
       int banderafind=0;
       try
       {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                       this.jtf_idcliente1.setText(rs.getString("id"));
                       this.jtf_direccionclie.setText(rs.getString("nombre"));
                       this.jtf_domcalle.setText(rs.getString("direccion"));
                       this.jtf_domcolonia.setText(rs.getString("colonia")+" "+rs.getString("poblacion"));
                       //this.jtf_dompobla1.setText(rs.getString("poblacion"));
                       this.jtf_email.setText(rs.getString("email")+" "+rs.getString("telefono"));
                       this.jtf_domcod.setText(rs.getString("cpcliente"));
                      // this.jtf_rfc.setText(rs.getString("rfc"));
                       //this.jtf_tel.setText(rs.getString("telefono"));
                       this.jtf_email1.setText(rs.getString("direccion2"));
                       //this.jtf_atnventas.setText(rs.getString("atnven"));
                       //this.jtf_atncobra.setText(rs.getString("atncob"));

                       this.jtf_cliobs.setText(rs.getString("obser"));
                       banderafind=1;
                }
        }
        catch(Exception e)
            {
            System.out.println(e.getMessage());
            }
        if (banderafind==1)
              {
               this.jtf_observaciones.requestFocus();
              }
         else
              {
                JOptionPane.showMessageDialog(null,"Cliente No existe", "Sistema Integral Alta Folio",1);
                this.jtf_idcliente.setText("");
                this.jtf_idcliente.requestFocus();
              }
   }

    private void guarda_cliente(int opcion)
    {
       String texto="select * from x1distribucion_terminados_ventas_clientes_alta("+opcion+",'"+this.jtf_idcliente1.getText().toString().toUpperCase().trim()+"','"+this.jtf_cliente.getText().toString().toUpperCase().trim()+"','"+this.jtf_domcalle1.getText().toString().toUpperCase().trim()+"','"+this.jtf_domcolonia1.getText().toString().toUpperCase().trim()+"','"+this.jtf_dompobla1.getText().toString().toUpperCase().trim()+"','"+this.jtf_cp.getText().toString().toUpperCase().trim()+"','"+this.jtf_rfc.getText().toString().toUpperCase()+"','','"+this.jtf_tel.getText().toString().toUpperCase()+"','','"+this.jtf_email.getText().toString().trim()+"','1','0','0','0','"+this.jtf_observaciones1.getText().toString().toUpperCase()+"','1','"+this.jtf_direccion2.getText().toString().toUpperCase()+"','"+this.jtf_atnventas.getText().toString().toUpperCase()+"','"+this.jtf_atncobra.getText().toString().toUpperCase()+"')";
       System.out.println(texto);
       int confirma=0;
        try
         {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                     confirma=rs.getInt(1);
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
       if (confirma>0)
              {
                JOptionPane.showMessageDialog(null,"Gracias datos Actualizados Correctamente", "Sistema Integral Proveedores",1);
                this.jtf_busqueda.setText(this.jtf_cliente.getText().trim().toUpperCase());
                this.buttonGroup2.setSelected(jrb_bdescrip.getModel(), true);
               this.carga_datos_clientes(3, this.jtf_cliente.getText().trim().toUpperCase());
               this.jtf_idcliente1.setText("0");
              }
         else
              {
                JOptionPane.showMessageDialog(null,"Error Consulte con Su Administrador", "Sistema Integral Proveedores",1);
              }
      }
private void dioclickcli(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
         System.out.println("dio doble  click");
         if(JOptionPane.showConfirmDialog(null, "Desea Seleccionar Clienta para Venta?")==0)
            {
                int fila = jt_clientes.getSelectedRow();
                String idcliente[] = jt_clientes.getValueAt(fila, 2).toString().split(":");
                this.jtf_idcliente.setText(idcliente[0]);
                this.jtf_direccionclie.setText(idcliente[1]);
                this.jtf_domcalle.setText(jt_clientes.getValueAt(fila, 3).toString());
                this.jtf_domcolonia.setText(jt_clientes.getValueAt(fila, 4).toString());
                this.jtf_domcod.setText(jt_clientes.getValueAt(fila, 6).toString());
                this.jtf_email.setText(jt_clientes.getValueAt(fila, 5).toString());
                this.jtf_email1.setText(jt_clientes.getValueAt(fila, 7).toString());
                this.jtf_cliobs.setText(jt_clientes.getValueAt(fila, 8).toString());
                this.jTabbedPane1.setSelectedIndex(0);
         }
    }
private void dioclickcliup(java.awt.event.MouseEvent evt) {
                 int fila = jt_clientes.getSelectedRow();
                 String idcliente[] = jt_clientes.getValueAt(fila, 2).toString().split(":");
                this.jtf_idmodi.setText(idcliente[0]);

    }
private void dioclickarti(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
         System.out.println("dio doble  click");
            this.verfotoindi();
    }
private void verfotoindi()
        {
                int fila =jtb_insumos.getSelectedRow();
                this.jep_articuloimagen.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+jtb_insumos.getValueAt(fila, 0).toString()+".JPG\" width=\"180\" height=\"160\" border=\"0\" alt=\"Foto Articulo\"></img>");
                this.jtf_deletefila.setText(String.valueOf(fila));
        }
private int pedido_detalleupdate(String codigo,String cantidad)
{
   int numeroarticulos=this.jtable_modelo_doctomovidet.getRowCount();
   String codigoactual="";
   float cantidadanterior=0,cantidadactual=0,totalpiezasf=0;
   int encontrado=0;
   for(int ii=0;ii<numeroarticulos;ii++)
                {
                    codigoactual=jtable_modelo_doctomovidet.getValueAt(ii, 0).toString();
                    if (codigo.equals(codigoactual))
                        {
                            encontrado=1;
                            cantidadanterior=Float.valueOf(jtable_modelo_doctomovidet.getValueAt(ii, 4).toString());
                            cantidadactual=cantidadanterior+Float.valueOf(cantidad);
                            jtable_modelo_doctomovidet.setValueAt(cantidadactual,ii ,4);
                            totalpiezasf=Float.valueOf(this.jtf_totalpiezas.getText().replace(",",""))+Float.valueOf(cantidad);
                            this.jtf_totalpiezas.setText(String.valueOf(totalpiezasf));
                            this.jtf_ultimocodigo.setText(codigo);
                            this.jtf_ultimodescripcion.setText(this.jtable_modelo_doctomovidet.getValueAt(ii, 1).toString());
                            this.jep_articuloimagen.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+codigo+".JPG\" width=\"180\" height=\"160\" border=\"0\" alt=\"Foto Articulo\"></img>");
                        }
                }
   if(encontrado==1)
        {
            this.calcularimportes();
            this.jtf_idarticulo.setText("");
        }
   return encontrado;
}


 private void jtb_almacen_controlMouseClicked(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
}
  private void dioclickartialma(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
        System.out.println("dio doble  click");
        int fila = jtb_almacen_control.getSelectedRow();
        this.jtf_filaactual.setText(String.valueOf(fila));
        String idcadena=this.jtable_modelo_almacen.getValueAt(fila, 0).toString();
        this.jep_articuloimagen1.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+idcadena+".JPG\" width=\"450\" height=\"400\" border=\"0\" alt=\"Foto Articulo\"></img>");
        this.jtf_codigosurtir.setText(idcadena);
        this.jtf_surtir.setText(this.jtable_modelo_almacen.getValueAt(fila, 5).toString());
    }
   private void dioclickartialmafoto(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
        System.out.println("dio doble  click");
        int fila = jtb_almacen_control.getSelectedRow();
        String id=this.jtable_modelo_almacen.getValueAt(fila, 0).toString();
        String des=this.jtable_modelo_almacen.getValueAt(fila, 1).toString();
        //String ite=this.jtable_modelo_almacen.getValueAt(fila, 2).toString();
        String pre1=this.jtable_modelo_almacen.getValueAt(fila, 2).toString();
        String pre2=this.jtable_modelo_almacen.getValueAt(fila, 3).toString();

        articulos_sie_editar_foto fasef=new articulos_sie_editar_foto(id,des,pre1,pre2);
        fasef.pack();
        RefineryUtilities.centerFrameOnScreen(fasef);
        
        fasef.setVisible(true);
    }

   private void crea_hoja_agregaexistencias(String codigo,String existencia,int columna)
    {
        DecimalFormat miformat = new DecimalFormat("###,###,###");
        int numerofilas=this.jtable_modelo_almacenexterno.getRowCount();
        String mesactual="";
        int numerocolumnas=this.jtable_modelo_almacenexterno.getColumnCount(),ii=00;
        int encontrado=0;
        Object[] fnewRow = new Object[numerocolumnas];
        float exialma=0,exialmaext=0,dif=0;
       //invoco al metodo que trae el recordset de datos
        exialma=Float.valueOf(existencia);
        for( ii=0;ii<numerofilas;ii++)
                {
                    mesactual=jtable_modelo_almacenexterno.getValueAt(ii, 0).toString();

                    if (mesactual.equals(codigo))
                        {
                        exialmaext=Float.valueOf(jtable_modelo_almacenexterno.getValueAt(ii, 3).toString());
                            encontrado=1;
                            dif=exialma-exialmaext;
                            jtable_modelo_almacenexterno.setValueAt(miformat.format(exialma),ii ,columna);
                            jtable_modelo_almacenexterno.setValueAt(miformat.format(exialma-exialmaext),ii ,5);
                            if(dif !=0)
                                {
                                 jtable_modelo_almacenexternodif.addRow(new Object[]{codigo,exialma,exialmaext,dif});
                                }
                        }
                }
    }
private void verexistenciasexternas()
        {
int numerofilas = this.jtable_modelo_almacenexterno.getRowCount(),ii=0;
String selectin="";
        for( ii=0;ii<numerofilas;ii++)
                {
                if (ii>0)
                    {
                        selectin+=".";
                    }
                selectin+=""+jtable_modelo_almacenexterno.getValueAt(ii ,0)+"";
                }

    System.out.println(selectin);

            String texto="select * from x1sieuno_articulo_detalle(1,"+"7"+",'','"+selectin+"') as (ida integer,min integer,max integer,exi double precision,idp integer,cod text,cndt integer,descor text,preve double precision,pre_re real,clavepro text)";
            System.out.println(texto);
            String despartido[]=null;
            int columnatitulo=0;
            try
               {
               rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongralext());
               while (rs.next())
                    {

                            despartido=rs.getString("descor").split(":");
                            System.out.println(rs.getString("clavepro")+" "+rs.getString("descor")+"en columna:"+columnatitulo);
                            this.crea_hoja_agregaexistencias(rs.getString("clavepro"),rs.getString("exi"),4);
                    }
                }
            catch(Exception e)
                {
                    System.out.println(e.getMessage());
                }
        }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        buttonGroup1 = new javax.swing.ButtonGroup();
        buttonGroup2 = new javax.swing.ButtonGroup();
        buttonGroup3 = new javax.swing.ButtonGroup();
        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel3 = new javax.swing.JPanel();
        jPanel2 = new javax.swing.JPanel();
        jtf_doctoreferencia = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        jtf_direccionclie = new javax.swing.JTextField();
        jtf_descuento = new javax.swing.JTextField();
        jLabel17 = new javax.swing.JLabel();
        jtf_observaciones = new javax.swing.JTextField();
        jtf_idcliente = new javax.swing.JTextField();
        jLabel3 = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        jdc_fechadocto = new com.toedter.calendar.JDateChooser();
        jLabel8 = new javax.swing.JLabel();
        jcmbx_almacenes = new javax.swing.JComboBox();
        jLabel6 = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        jtf_domcod = new javax.swing.JTextField();
        jtf_domcalle = new javax.swing.JTextField();
        jLabel7 = new javax.swing.JLabel();
        jLabel4 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        jtf_domcolonia = new javax.swing.JTextField();
        jtf_impuesto = new javax.swing.JTextField();
        jLabel23 = new javax.swing.JLabel();
        jtf_email = new javax.swing.JTextField();
        jtf_email1 = new javax.swing.JTextField();
        jLabel21 = new javax.swing.JLabel();
        jLabel33 = new javax.swing.JLabel();
        jtf_cliobs = new javax.swing.JTextField();
        jcbx_idmoneda = new javax.swing.JComboBox();
        jLabel45 = new javax.swing.JLabel();
        jtf_tipocambio = new javax.swing.JTextField();
        jLabel10 = new javax.swing.JLabel();
        jcbx_verificadorprecio = new javax.swing.JCheckBox();
        jPanel4 = new javax.swing.JPanel();
        jLabel5 = new javax.swing.JLabel();
        jtf_canpzaingresa = new javax.swing.JTextField();
        jLabel14 = new javax.swing.JLabel();
        jtf_idarticulo = new javax.swing.JTextField();
        jbtn_buscaridinsu = new javax.swing.JButton();
        jrbtn_precio1 = new javax.swing.JRadioButton();
        jrbtn_preciom = new javax.swing.JRadioButton();
        jLabel9 = new javax.swing.JLabel();
        jtf_ultimocodigo = new javax.swing.JTextField();
        jtf_ultimodescripcion = new javax.swing.JTextField();
        jtf_idarticuloobserva = new javax.swing.JTextField();
        jpn_cuerpo = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jtb_insumos = new javax.swing.JTable()
        {
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                if ((mColIndex < 3) ||  (mColIndex ==5) )
                return false;
                else
                return true;
            }
        }
        ;
        jScrollPane2 = new javax.swing.JScrollPane();
        jep_articuloimagen = new javax.swing.JEditorPane();
        jLabel11 = new javax.swing.JLabel();
        jtf_doctosubtotal = new javax.swing.JTextField();
        jLabel12 = new javax.swing.JLabel();
        jtf_doctodesc = new javax.swing.JTextField();
        jLabel13 = new javax.swing.JLabel();
        jtf_doctoimp = new javax.swing.JTextField();
        jLabel15 = new javax.swing.JLabel();
        jtf_doctototal = new javax.swing.JTextField();
        jLabel18 = new javax.swing.JLabel();
        jtf_totalpiezas = new javax.swing.JTextField();
        jtf_deletefila = new javax.swing.JTextField();
        jchbx_eliminarfila = new javax.swing.JCheckBox();
        jlbl_monedadescribe = new javax.swing.JLabel();
        jtf_conversionmoneda = new javax.swing.JTextField();
        jPanel9 = new javax.swing.JPanel();
        jlbl_formatoarchivo = new javax.swing.JLabel();
        jbtn_importar = new javax.swing.JButton();
        jScrollPane3 = new javax.swing.JScrollPane();
        jta_archivo = new javax.swing.JTextArea();
        jbtn_guardar = new javax.swing.JButton();
        jPanel1 = new javax.swing.JPanel();
        jPanel5 = new javax.swing.JPanel();
        jrb_direccion = new javax.swing.JRadioButton();
        jrb_bdescrip = new javax.swing.JRadioButton();
        jrb_bclave = new javax.swing.JRadioButton();
        jLabel22 = new javax.swing.JLabel();
        jtf_busqueda = new javax.swing.JTextField();
        jbtn_buscar = new javax.swing.JButton();
        jScrollPane4 = new javax.swing.JScrollPane();
        jt_clientes = new javax.swing.JTable()
        {
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                return false;
            }
        }
        ;
        jLabel24 = new javax.swing.JLabel();
        jLabel25 = new javax.swing.JLabel();
        jlbl_cantidadregistros = new javax.swing.JLabel();
        jLabel26 = new javax.swing.JLabel();
        jlbl_textobuscado = new javax.swing.JLabel();
        jLabel44 = new javax.swing.JLabel();
        jtf_idmodi = new javax.swing.JTextField();
        jbtn_actualizar = new javax.swing.JButton();
        jcbx_nuevocli = new javax.swing.JCheckBox();
        jPanel7 = new javax.swing.JPanel();
        jtf_cliente = new javax.swing.JTextField();
        jLabel28 = new javax.swing.JLabel();
        jtf_observaciones1 = new javax.swing.JTextField();
        jtf_idcliente1 = new javax.swing.JTextField();
        jLabel30 = new javax.swing.JLabel();
        jtf_dompobla1 = new javax.swing.JTextField();
        jtf_cp = new javax.swing.JTextField();
        jtf_domcalle1 = new javax.swing.JTextField();
        jLabel34 = new javax.swing.JLabel();
        jLabel35 = new javax.swing.JLabel();
        jLabel36 = new javax.swing.JLabel();
        jLabel37 = new javax.swing.JLabel();
        jtf_domcolonia1 = new javax.swing.JTextField();
        jLabel38 = new javax.swing.JLabel();
        jtf_email2 = new javax.swing.JTextField();
        jtf_direccion2 = new javax.swing.JTextField();
        jLabel39 = new javax.swing.JLabel();
        jtf_rfc = new javax.swing.JTextField();
        jLabel40 = new javax.swing.JLabel();
        jtf_tel = new javax.swing.JTextField();
        jLabel41 = new javax.swing.JLabel();
        jLabel42 = new javax.swing.JLabel();
        jtf_atnventas = new javax.swing.JTextField();
        jLabel43 = new javax.swing.JLabel();
        jtf_atncobra = new javax.swing.JTextField();
        jbtn_guardar1 = new javax.swing.JButton();
        jPanel8 = new javax.swing.JPanel();
        jPanel10 = new javax.swing.JPanel();
        jScrollPane6 = new javax.swing.JScrollPane();
        jep_articuloimagen1 = new javax.swing.JEditorPane();
        jLabel19 = new javax.swing.JLabel();
        jtf_surtir = new javax.swing.JTextField();
        jLabel27 = new javax.swing.JLabel();
        jtf_codigosurtir = new javax.swing.JTextField();
        jbtn_surtir = new javax.swing.JButton();
        jLabel29 = new javax.swing.JLabel();
        jtf_totalpiezas1 = new javax.swing.JTextField();
        jLabel31 = new javax.swing.JLabel();
        jtf_doctototal1 = new javax.swing.JTextField();
        jPanel11 = new javax.swing.JPanel();
        jScrollPane5 = new javax.swing.JScrollPane();
        jtb_almacen_control = new javax.swing.JTable()
        {
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                return false;
            }
        }
        ;
        jrb_bclave1 = new javax.swing.JRadioButton();
        jrb_bitem = new javax.swing.JRadioButton();
        jrb_bdescrip1 = new javax.swing.JRadioButton();
        jtf_busqueda1 = new javax.swing.JTextField();
        jLabel32 = new javax.swing.JLabel();
        jcbx_linea = new javax.swing.JComboBox();
        jbtn_buscar1 = new javax.swing.JButton();
        jtf_filaactual = new javax.swing.JTextField();
        jbtn_anterior = new javax.swing.JButton();
        jbtn_siguiente = new javax.swing.JButton();
        jPanel6 = new javax.swing.JPanel();
        jScrollPane7 = new javax.swing.JScrollPane();
        jtb_almacen_control1 = new javax.swing.JTable()
        {
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                return false;
            }
        }
        ;
        jbtn_ajustaexistencia = new javax.swing.JButton();
        jScrollPane8 = new javax.swing.JScrollPane();
        jtb_almacen_control2 = new javax.swing.JTable()
        {
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                return false;
            }
        }
        ;
        jMenuBar1 = new javax.swing.JMenuBar();
        jMenu1 = new javax.swing.JMenu();
        jmni_verificadorprecio = new javax.swing.JMenuItem();
        jmni_salir = new javax.swing.JMenuItem();
        jMenu2 = new javax.swing.JMenu();
        jmni_escape = new javax.swing.JMenuItem();
        jmni_buscar = new javax.swing.JMenuItem();
        jmni_guardar = new javax.swing.JMenuItem();
        jMenuItem1 = new javax.swing.JMenuItem();
        jmni_anterior = new javax.swing.JMenuItem();
        jmni_importar = new javax.swing.JMenuItem();
        jMenu3 = new javax.swing.JMenu();

        setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE);
        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(sie_invdis.Sie_invdisApp.class).getContext().getResourceMap(com_distri_folios_agregar.class);
        setTitle(resourceMap.getString("Form.title")); // NOI18N
        setName("Form"); // NOI18N

        jTabbedPane1.setName("jTabbedPane1"); // NOI18N
        jTabbedPane1.addChangeListener(new javax.swing.event.ChangeListener() {
            public void stateChanged(javax.swing.event.ChangeEvent evt) {
                jTabbedPane1StateChanged(evt);
            }
        });

        jPanel3.setBorder(javax.swing.BorderFactory.createEmptyBorder(1, 1, 1, 1));
        jPanel3.setName("jPanel3"); // NOI18N

        jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jPanel2.border.title"))); // NOI18N
        jPanel2.setName("jPanel2"); // NOI18N

        jtf_doctoreferencia.setName("jtf_doctoreferencia"); // NOI18N
        jtf_doctoreferencia.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_doctoreferenciaActionPerformed(evt);
            }
        });

        jLabel2.setText(resourceMap.getString("jLabel2.text")); // NOI18N
        jLabel2.setName("jLabel2"); // NOI18N

        jtf_direccionclie.setEditable(false);
        jtf_direccionclie.setText(resourceMap.getString("jtf_direccionclie.text")); // NOI18N
        jtf_direccionclie.setName("jtf_direccionclie"); // NOI18N

        jtf_descuento.setText(resourceMap.getString("jtf_descuento.text")); // NOI18N
        jtf_descuento.setName("jtf_descuento"); // NOI18N

        jLabel17.setText(resourceMap.getString("jLabel17.text")); // NOI18N
        jLabel17.setName("jLabel17"); // NOI18N

        jtf_observaciones.setName("jtf_observaciones"); // NOI18N
        jtf_observaciones.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_observacionesActionPerformed(evt);
            }
        });

        jtf_idcliente.setText(resourceMap.getString("jtf_idcliente.text")); // NOI18N
        jtf_idcliente.setAutoscrolls(false);
        jtf_idcliente.setName("jtf_idcliente"); // NOI18N
        jtf_idcliente.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_idclienteActionPerformed(evt);
            }
        });

        jLabel3.setText(resourceMap.getString("jLabel3.text")); // NOI18N
        jLabel3.setName("jLabel3"); // NOI18N

        jLabel20.setText(resourceMap.getString("jLabel20.text")); // NOI18N
        jLabel20.setName("jLabel20"); // NOI18N

        jdc_fechadocto.setDateFormatString(resourceMap.getString("jdc_fechadocto.dateFormatString")); // NOI18N
        jdc_fechadocto.setName("jdc_fechadocto"); // NOI18N

        jLabel8.setText(resourceMap.getString("jLabel8.text")); // NOI18N
        jLabel8.setName("jLabel8"); // NOI18N

        jcmbx_almacenes.setName("jcmbx_almacenes"); // NOI18N
        jcmbx_almacenes.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcmbx_almacenesActionPerformed(evt);
            }
        });

        jLabel6.setText(resourceMap.getString("jLabel6.text")); // NOI18N
        jLabel6.setName("jLabel6"); // NOI18N

        jLabel1.setText(resourceMap.getString("jLabel1.text")); // NOI18N
        jLabel1.setName("jLabel1"); // NOI18N

        jtf_domcod.setEditable(false);
        jtf_domcod.setName("jtf_domcod"); // NOI18N
        jtf_domcod.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_domcodActionPerformed(evt);
            }
        });

        jtf_domcalle.setEditable(false);
        jtf_domcalle.setName("jtf_domcalle"); // NOI18N
        jtf_domcalle.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_domcalleActionPerformed(evt);
            }
        });

        jLabel7.setText(resourceMap.getString("jLabel7.text")); // NOI18N
        jLabel7.setName("jLabel7"); // NOI18N

        jLabel4.setText(resourceMap.getString("jLabel4.text")); // NOI18N
        jLabel4.setName("jLabel4"); // NOI18N

        jLabel16.setText(resourceMap.getString("jLabel16.text")); // NOI18N
        jLabel16.setName("jLabel16"); // NOI18N

        jtf_domcolonia.setEditable(false);
        jtf_domcolonia.setName("jtf_domcolonia"); // NOI18N
        jtf_domcolonia.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_domcoloniaActionPerformed(evt);
            }
        });

        jtf_impuesto.setText(resourceMap.getString("jtf_impuesto.text")); // NOI18N
        jtf_impuesto.setName("jtf_impuesto"); // NOI18N

        jLabel23.setText(resourceMap.getString("jLabel23.text")); // NOI18N
        jLabel23.setName("jLabel23"); // NOI18N

        jtf_email.setEditable(false);
        jtf_email.setName("jtf_email"); // NOI18N
        jtf_email.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_emailActionPerformed(evt);
            }
        });

        jtf_email1.setEditable(false);
        jtf_email1.setName("jtf_email1"); // NOI18N
        jtf_email1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_email1ActionPerformed(evt);
            }
        });

        jLabel21.setText(resourceMap.getString("jLabel21.text")); // NOI18N
        jLabel21.setName("jLabel21"); // NOI18N

        jLabel33.setText(resourceMap.getString("jLabel33.text")); // NOI18N
        jLabel33.setName("jLabel33"); // NOI18N

        jtf_cliobs.setEditable(false);
        jtf_cliobs.setText(resourceMap.getString("jtf_cliobs.text")); // NOI18N
        jtf_cliobs.setName("jtf_cliobs"); // NOI18N

        jcbx_idmoneda.setName("jcbx_idmoneda"); // NOI18N
        jcbx_idmoneda.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbx_idmonedaActionPerformed(evt);
            }
        });

        jLabel45.setText(resourceMap.getString("jLabel45.text")); // NOI18N
        jLabel45.setName("jLabel45"); // NOI18N

        jtf_tipocambio.setFont(resourceMap.getFont("jtf_tipocambio.font")); // NOI18N
        jtf_tipocambio.setText(resourceMap.getString("jtf_tipocambio.text")); // NOI18N
        jtf_tipocambio.setName("jtf_tipocambio"); // NOI18N
        jtf_tipocambio.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_tipocambioActionPerformed(evt);
            }
        });

        jLabel10.setText(resourceMap.getString("jLabel10.text")); // NOI18N
        jLabel10.setName("jLabel10"); // NOI18N

        jcbx_verificadorprecio.setFont(resourceMap.getFont("jcbx_verificadorprecio.font")); // NOI18N
        jcbx_verificadorprecio.setText(resourceMap.getString("jcbx_verificadorprecio.text")); // NOI18N
        jcbx_verificadorprecio.setName("jcbx_verificadorprecio"); // NOI18N
        jcbx_verificadorprecio.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbx_verificadorprecioActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(jLabel2)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jdc_fechadocto, javax.swing.GroupLayout.PREFERRED_SIZE, 128, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel6)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jcmbx_almacenes, javax.swing.GroupLayout.PREFERRED_SIZE, 117, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel3)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_doctoreferencia, javax.swing.GroupLayout.PREFERRED_SIZE, 66, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel7, javax.swing.GroupLayout.PREFERRED_SIZE, 47, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_idcliente, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_direccionclie, javax.swing.GroupLayout.DEFAULT_SIZE, 279, Short.MAX_VALUE))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addComponent(jLabel4)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jtf_observaciones, javax.swing.GroupLayout.PREFERRED_SIZE, 298, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel45)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jcbx_idmoneda, javax.swing.GroupLayout.PREFERRED_SIZE, 147, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel10)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_tipocambio, javax.swing.GroupLayout.PREFERRED_SIZE, 70, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(jLabel16)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_domcalle))
                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel2Layout.createSequentialGroup()
                                .addComponent(jLabel20)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_domcod, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel23)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_email, javax.swing.GroupLayout.PREFERRED_SIZE, 155, javax.swing.GroupLayout.PREFERRED_SIZE)))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(jLabel17)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_domcolonia, javax.swing.GroupLayout.PREFERRED_SIZE, 249, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(jLabel21)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_email1)))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(jLabel33)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_cliobs, javax.swing.GroupLayout.DEFAULT_SIZE, 190, Short.MAX_VALUE))
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addGap(20, 20, 20)
                                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel2Layout.createSequentialGroup()
                                        .addGap(10, 10, 10)
                                        .addComponent(jcbx_verificadorprecio))
                                    .addGroup(jPanel2Layout.createSequentialGroup()
                                        .addComponent(jLabel1)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_descuento, javax.swing.GroupLayout.PREFERRED_SIZE, 60, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                        .addComponent(jLabel8)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_impuesto)))))))
                .addContainerGap())
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel2)
                    .addComponent(jdc_fechadocto, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jcmbx_almacenes, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jLabel3)
                        .addComponent(jtf_doctoreferencia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jLabel6)
                        .addComponent(jLabel7)
                        .addComponent(jtf_idcliente, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jtf_direccionclie, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel16)
                            .addComponent(jtf_domcalle, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel20)
                            .addComponent(jtf_domcod, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jtf_email, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel23)
                            .addComponent(jLabel21)
                            .addComponent(jtf_email1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jLabel17)
                        .addComponent(jtf_domcolonia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel33)
                            .addComponent(jtf_cliobs, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel1)
                            .addComponent(jtf_descuento, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel8)
                            .addComponent(jtf_impuesto, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel4)
                    .addComponent(jtf_observaciones, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel45)
                    .addComponent(jcbx_idmoneda, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel10)
                    .addComponent(jtf_tipocambio, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jcbx_verificadorprecio, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jPanel4.border.title"))); // NOI18N
        jPanel4.setName("jPanel4"); // NOI18N

        jLabel5.setText(resourceMap.getString("jLabel5.text")); // NOI18N
        jLabel5.setName("jLabel5"); // NOI18N

        jtf_canpzaingresa.setText(resourceMap.getString("jtf_canpzaingresa.text")); // NOI18N
        jtf_canpzaingresa.setToolTipText(resourceMap.getString("jtf_canpzaingresa.toolTipText")); // NOI18N
        jtf_canpzaingresa.setName("jtf_canpzaingresa"); // NOI18N
        jtf_canpzaingresa.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_canpzaingresaActionPerformed(evt);
            }
        });

        jLabel14.setText(resourceMap.getString("jLabel14.text")); // NOI18N
        jLabel14.setName("jLabel14"); // NOI18N

        jtf_idarticulo.setToolTipText(resourceMap.getString("jtf_idarticulo.toolTipText")); // NOI18N
        jtf_idarticulo.setName("jtf_idarticulo"); // NOI18N
        jtf_idarticulo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_idarticuloActionPerformed(evt);
            }
        });

        jbtn_buscaridinsu.setIcon(resourceMap.getIcon("jbtn_buscaridinsu.icon")); // NOI18N
        jbtn_buscaridinsu.setText(resourceMap.getString("jbtn_buscaridinsu.text")); // NOI18N
        jbtn_buscaridinsu.setName("jbtn_buscaridinsu"); // NOI18N
        jbtn_buscaridinsu.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_buscaridinsuActionPerformed(evt);
            }
        });

        buttonGroup1.add(jrbtn_precio1);
        jrbtn_precio1.setText(resourceMap.getString("jrbtn_precio1.text")); // NOI18N
        jrbtn_precio1.setToolTipText(resourceMap.getString("jrbtn_precio1.toolTipText")); // NOI18N
        jrbtn_precio1.setActionCommand(resourceMap.getString("jrbtn_precio1.actionCommand")); // NOI18N
        jrbtn_precio1.setName("jrbtn_precio1"); // NOI18N
        jrbtn_precio1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrbtn_precio1ActionPerformed(evt);
            }
        });

        buttonGroup1.add(jrbtn_preciom);
        jrbtn_preciom.setText(resourceMap.getString("jrbtn_preciom.text")); // NOI18N
        jrbtn_preciom.setActionCommand(resourceMap.getString("jrbtn_preciom.actionCommand")); // NOI18N
        jrbtn_preciom.setName("jrbtn_preciom"); // NOI18N
        jrbtn_preciom.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrbtn_preciomActionPerformed(evt);
            }
        });

        jLabel9.setText(resourceMap.getString("jLabel9.text")); // NOI18N
        jLabel9.setName("jLabel9"); // NOI18N

        jtf_ultimocodigo.setEditable(false);
        jtf_ultimocodigo.setFont(resourceMap.getFont("jtf_ultimocodigo.font")); // NOI18N
        jtf_ultimocodigo.setText(resourceMap.getString("jtf_ultimocodigo.text")); // NOI18N
        jtf_ultimocodigo.setName("jtf_ultimocodigo"); // NOI18N

        jtf_ultimodescripcion.setEditable(false);
        jtf_ultimodescripcion.setText(resourceMap.getString("jtf_ultimodescripcion.text")); // NOI18N
        jtf_ultimodescripcion.setName("jtf_ultimodescripcion"); // NOI18N

        jtf_idarticuloobserva.setToolTipText(resourceMap.getString("jtf_idarticuloobserva.toolTipText")); // NOI18N
        jtf_idarticuloobserva.setName("jtf_idarticuloobserva"); // NOI18N
        jtf_idarticuloobserva.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_idarticuloobservaActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addComponent(jLabel5)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jtf_canpzaingresa, javax.swing.GroupLayout.PREFERRED_SIZE, 37, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel14)
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addGap(28, 28, 28)
                        .addComponent(jrbtn_precio1)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jrbtn_preciom)
                        .addGap(82, 82, 82)
                        .addComponent(jLabel9))
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_idarticulo, javax.swing.GroupLayout.PREFERRED_SIZE, 121, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_idarticuloobserva, javax.swing.GroupLayout.PREFERRED_SIZE, 162, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jbtn_buscaridinsu, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jtf_ultimocodigo, javax.swing.GroupLayout.PREFERRED_SIZE, 141, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jtf_ultimodescripcion, javax.swing.GroupLayout.PREFERRED_SIZE, 261, javax.swing.GroupLayout.PREFERRED_SIZE))
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jtf_canpzaingresa, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel5)
                            .addComponent(jLabel14)
                            .addComponent(jtf_idarticulo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jbtn_buscaridinsu)
                            .addComponent(jtf_idarticuloobserva, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jrbtn_precio1, javax.swing.GroupLayout.PREFERRED_SIZE, 13, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jrbtn_preciom, javax.swing.GroupLayout.PREFERRED_SIZE, 16, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel9)))
                    .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jtf_ultimocodigo, javax.swing.GroupLayout.PREFERRED_SIZE, 34, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jtf_ultimodescripcion, javax.swing.GroupLayout.PREFERRED_SIZE, 34, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );

        jpn_cuerpo.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jpn_cuerpo.border.title"))); // NOI18N
        jpn_cuerpo.setName("jpn_cuerpo"); // NOI18N

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        jtb_insumos.setModel(this.jtable_modelo_doctomovidet);
        jtb_insumos.setName("jtb_insumos"); // NOI18N
        jtb_insumos.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jtb_insumosMouseClicked(evt);
                if(evt.getClickCount() >= 1)
                {
                    dioclickarti(evt);
                    //System.out.println(" double click" );
                }
            }
        });
        jtb_insumos.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
            public void propertyChange(java.beans.PropertyChangeEvent evt) {
                jtb_insumosPropertyChange(evt);
            }
        });
        jtb_insumos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                jtb_insumosKeyPressed(evt);
            }
        });
        jScrollPane1.setViewportView(jtb_insumos);

        jScrollPane2.setName("jScrollPane2"); // NOI18N

        jep_articuloimagen.setContentType(resourceMap.getString("jep_articuloimagen.contentType")); // NOI18N
        jep_articuloimagen.setName("jep_articuloimagen"); // NOI18N
        jScrollPane2.setViewportView(jep_articuloimagen);

        jLabel11.setText(resourceMap.getString("jLabel11.text")); // NOI18N
        jLabel11.setName("jLabel11"); // NOI18N

        jtf_doctosubtotal.setEditable(false);
        jtf_doctosubtotal.setFont(resourceMap.getFont("jtf_doctosubtotal.font")); // NOI18N
        jtf_doctosubtotal.setName("jtf_doctosubtotal"); // NOI18N

        jLabel12.setText(resourceMap.getString("jLabel12.text")); // NOI18N
        jLabel12.setName("jLabel12"); // NOI18N

        jtf_doctodesc.setEditable(false);
        jtf_doctodesc.setFont(resourceMap.getFont("jtf_doctodesc.font")); // NOI18N
        jtf_doctodesc.setName("jtf_doctodesc"); // NOI18N

        jLabel13.setText(resourceMap.getString("jLabel13.text")); // NOI18N
        jLabel13.setName("jLabel13"); // NOI18N

        jtf_doctoimp.setEditable(false);
        jtf_doctoimp.setFont(resourceMap.getFont("jtf_doctoimp.font")); // NOI18N
        jtf_doctoimp.setName("jtf_doctoimp"); // NOI18N

        jLabel15.setText(resourceMap.getString("jLabel15.text")); // NOI18N
        jLabel15.setName("jLabel15"); // NOI18N

        jtf_doctototal.setEditable(false);
        jtf_doctototal.setFont(resourceMap.getFont("jtf_doctototal.font")); // NOI18N
        jtf_doctototal.setName("jtf_doctototal"); // NOI18N

        jLabel18.setText(resourceMap.getString("jLabel18.text")); // NOI18N
        jLabel18.setName("jLabel18"); // NOI18N

        jtf_totalpiezas.setEditable(false);
        jtf_totalpiezas.setFont(resourceMap.getFont("jtf_totalpiezas.font")); // NOI18N
        jtf_totalpiezas.setText(resourceMap.getString("jtf_totalpiezas.text")); // NOI18N
        jtf_totalpiezas.setName("jtf_totalpiezas"); // NOI18N

        jtf_deletefila.setEditable(false);
        jtf_deletefila.setText(resourceMap.getString("jtf_deletefila.text")); // NOI18N
        jtf_deletefila.setName("jtf_deletefila"); // NOI18N

        jchbx_eliminarfila.setText(resourceMap.getString("jchbx_eliminarfila.text")); // NOI18N
        jchbx_eliminarfila.setName("jchbx_eliminarfila"); // NOI18N
        jchbx_eliminarfila.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jchbx_eliminarfilaActionPerformed(evt);
            }
        });

        jlbl_monedadescribe.setFont(resourceMap.getFont("jlbl_monedadescribe.font")); // NOI18N
        jlbl_monedadescribe.setText(resourceMap.getString("jlbl_monedadescribe.text")); // NOI18N
        jlbl_monedadescribe.setName("jlbl_monedadescribe"); // NOI18N

        jtf_conversionmoneda.setEditable(false);
        jtf_conversionmoneda.setFont(resourceMap.getFont("jtf_conversionmoneda.font")); // NOI18N
        jtf_conversionmoneda.setText(resourceMap.getString("jtf_conversionmoneda.text")); // NOI18N
        jtf_conversionmoneda.setName("jtf_conversionmoneda"); // NOI18N

        jPanel9.setName("jPanel9"); // NOI18N

        jlbl_formatoarchivo.setText(resourceMap.getString("jlbl_formatoarchivo.text")); // NOI18N
        jlbl_formatoarchivo.setName("jlbl_formatoarchivo"); // NOI18N

        jbtn_importar.setIcon(resourceMap.getIcon("jbtn_importar.icon")); // NOI18N
        jbtn_importar.setText(resourceMap.getString("jbtn_importar.text")); // NOI18N
        jbtn_importar.setName("jbtn_importar"); // NOI18N
        jbtn_importar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_importarActionPerformed(evt);
            }
        });

        jScrollPane3.setName("jScrollPane3"); // NOI18N

        jta_archivo.setColumns(20);
        jta_archivo.setRows(5);
        jta_archivo.setName("jta_archivo"); // NOI18N
        jScrollPane3.setViewportView(jta_archivo);

        javax.swing.GroupLayout jPanel9Layout = new javax.swing.GroupLayout(jPanel9);
        jPanel9.setLayout(jPanel9Layout);
        jPanel9Layout.setHorizontalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel9Layout.createSequentialGroup()
                .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 239, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jbtn_importar, javax.swing.GroupLayout.PREFERRED_SIZE, 107, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jlbl_formatoarchivo))
                .addGap(21, 21, 21))
        );
        jPanel9Layout.setVerticalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel9Layout.createSequentialGroup()
                .addGroup(jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel9Layout.createSequentialGroup()
                        .addComponent(jlbl_formatoarchivo, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(jbtn_importar))
                    .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 41, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        jbtn_guardar.setFont(resourceMap.getFont("jbtn_guardar.font")); // NOI18N
        jbtn_guardar.setIcon(resourceMap.getIcon("jbtn_guardar.icon")); // NOI18N
        jbtn_guardar.setText(resourceMap.getString("jbtn_guardar.text")); // NOI18N
        jbtn_guardar.setName("jbtn_guardar"); // NOI18N
        jbtn_guardar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_guardarActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jpn_cuerpoLayout = new javax.swing.GroupLayout(jpn_cuerpo);
        jpn_cuerpo.setLayout(jpn_cuerpoLayout);
        jpn_cuerpoLayout.setHorizontalGroup(
            jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jpn_cuerpoLayout.createSequentialGroup()
                .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jScrollPane1)
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addComponent(jPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, 464, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jbtn_guardar, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addComponent(jtf_deletefila, javax.swing.GroupLayout.PREFERRED_SIZE, 22, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jchbx_eliminarfila)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel18)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_totalpiezas, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel11)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_doctosubtotal, javax.swing.GroupLayout.PREFERRED_SIZE, 68, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel12)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_doctodesc, javax.swing.GroupLayout.PREFERRED_SIZE, 68, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jLabel13)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_doctoimp, javax.swing.GroupLayout.PREFERRED_SIZE, 66, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jLabel15)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_doctototal, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(15, 15, 15)
                .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                        .addComponent(jtf_conversionmoneda, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jpn_cuerpoLayout.createSequentialGroup()
                            .addComponent(jlbl_monedadescribe)
                            .addGap(104, 104, 104)))
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 196, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jpn_cuerpoLayout.setVerticalGroup(
            jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 177, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jlbl_monedadescribe, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addGap(20, 20, 20))
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 214, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)))
                .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jtf_deletefila, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jchbx_eliminarfila)
                            .addComponent(jtf_doctodesc, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel13)
                            .addComponent(jtf_doctoimp, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel15)
                            .addComponent(jtf_doctototal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel11)
                            .addComponent(jtf_doctosubtotal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel12)
                            .addComponent(jtf_totalpiezas, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel18))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jpn_cuerpoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jbtn_guardar)))
                    .addGroup(jpn_cuerpoLayout.createSequentialGroup()
                        .addComponent(jtf_conversionmoneda, javax.swing.GroupLayout.DEFAULT_SIZE, 67, Short.MAX_VALUE)
                        .addContainerGap())))
        );

        javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
        jPanel3.setLayout(jPanel3Layout);
        jPanel3Layout.setHorizontalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jPanel4, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jpn_cuerpo, 0, 943, Short.MAX_VALUE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel3Layout.setVerticalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, 143, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, 75, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jpn_cuerpo, javax.swing.GroupLayout.DEFAULT_SIZE, 324, Short.MAX_VALUE)
                .addContainerGap())
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel3.TabConstraints.tabTitle"), jPanel3); // NOI18N

        jPanel1.setName("jPanel1"); // NOI18N

        jPanel5.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jPanel5.border.title"))); // NOI18N
        jPanel5.setName("jPanel5"); // NOI18N

        buttonGroup2.add(jrb_direccion);
        jrb_direccion.setText(resourceMap.getString("jrb_direccion.text")); // NOI18N
        jrb_direccion.setToolTipText(resourceMap.getString("jrb_direccion.toolTipText")); // NOI18N
        jrb_direccion.setActionCommand(resourceMap.getString("jrb_direccion.actionCommand")); // NOI18N
        jrb_direccion.setName("jrb_direccion"); // NOI18N
        jrb_direccion.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_direccionActionPerformed(evt);
            }
        });

        buttonGroup2.add(jrb_bdescrip);
        jrb_bdescrip.setText(resourceMap.getString("jrb_bdescrip.text")); // NOI18N
        jrb_bdescrip.setToolTipText(resourceMap.getString("jrb_bdescrip.toolTipText")); // NOI18N
        jrb_bdescrip.setActionCommand(resourceMap.getString("jrb_bdescrip.actionCommand")); // NOI18N
        jrb_bdescrip.setName("jrb_bdescrip"); // NOI18N
        jrb_bdescrip.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_bdescripActionPerformed(evt);
            }
        });

        buttonGroup2.add(jrb_bclave);
        jrb_bclave.setText(resourceMap.getString("jrb_bclave.text")); // NOI18N
        jrb_bclave.setToolTipText(resourceMap.getString("jrb_bclave.toolTipText")); // NOI18N
        jrb_bclave.setActionCommand(resourceMap.getString("jrb_bclave.actionCommand")); // NOI18N
        jrb_bclave.setName("jrb_bclave"); // NOI18N
        jrb_bclave.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_bclaveActionPerformed(evt);
            }
        });

        jLabel22.setText(resourceMap.getString("jLabel22.text")); // NOI18N
        jLabel22.setName("jLabel22"); // NOI18N

        jtf_busqueda.setToolTipText(resourceMap.getString("jtf_busqueda.toolTipText")); // NOI18N
        jtf_busqueda.setName("jtf_busqueda"); // NOI18N
        jtf_busqueda.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_busquedaActionPerformed(evt);
            }
        });

        jbtn_buscar.setIcon(resourceMap.getIcon("jbtn_buscar.icon")); // NOI18N
        jbtn_buscar.setText(resourceMap.getString("jbtn_buscar.text")); // NOI18N
        jbtn_buscar.setName("jbtn_buscar"); // NOI18N
        jbtn_buscar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_buscarActionPerformed(evt);
            }
        });

        jScrollPane4.setName("jScrollPane4"); // NOI18N

        jt_clientes.setModel(this.jtable_modelo_cliente);
        jt_clientes.setName("jt_clientes"); // NOI18N
        jt_clientes.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jt_clientesMouseClicked(evt);
                if(evt.getClickCount() >= 2)
                {
                    dioclickcli(evt);
                }
                if(evt.getClickCount() >= 1)
                {
                    dioclickcliup(evt);
                }
            }
        });
        jScrollPane4.setViewportView(jt_clientes);

        jLabel24.setText(resourceMap.getString("jLabel24.text")); // NOI18N
        jLabel24.setName("jLabel24"); // NOI18N

        jLabel25.setFont(resourceMap.getFont("jLabel25.font")); // NOI18N
        jLabel25.setText(resourceMap.getString("jLabel25.text")); // NOI18N
        jLabel25.setName("jLabel25"); // NOI18N

        jlbl_cantidadregistros.setFont(resourceMap.getFont("jlbl_cantidadregistros.font")); // NOI18N
        jlbl_cantidadregistros.setText(resourceMap.getString("jlbl_cantidadregistros.text")); // NOI18N
        jlbl_cantidadregistros.setName("jlbl_cantidadregistros"); // NOI18N

        jLabel26.setFont(resourceMap.getFont("jLabel26.font")); // NOI18N
        jLabel26.setText(resourceMap.getString("jLabel26.text")); // NOI18N
        jLabel26.setName("jLabel26"); // NOI18N

        jlbl_textobuscado.setFont(resourceMap.getFont("jlbl_textobuscado.font")); // NOI18N
        jlbl_textobuscado.setText(resourceMap.getString("jlbl_textobuscado.text")); // NOI18N
        jlbl_textobuscado.setName("jlbl_textobuscado"); // NOI18N

        jLabel44.setText(resourceMap.getString("jLabel44.text")); // NOI18N
        jLabel44.setName("jLabel44"); // NOI18N

        jtf_idmodi.setEditable(false);
        jtf_idmodi.setText(resourceMap.getString("jtf_idmodi.text")); // NOI18N
        jtf_idmodi.setAutoscrolls(false);
        jtf_idmodi.setName("jtf_idmodi"); // NOI18N

        jbtn_actualizar.setIcon(resourceMap.getIcon("jbtn_actualizar.icon")); // NOI18N
        jbtn_actualizar.setText(resourceMap.getString("jbtn_actualizar.text")); // NOI18N
        jbtn_actualizar.setToolTipText(resourceMap.getString("jbtn_actualizar.toolTipText")); // NOI18N
        jbtn_actualizar.setName("jbtn_actualizar"); // NOI18N
        jbtn_actualizar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_actualizarActionPerformed(evt);
            }
        });

        jcbx_nuevocli.setText(resourceMap.getString("jcbx_nuevocli.text")); // NOI18N
        jcbx_nuevocli.setName("jcbx_nuevocli"); // NOI18N
        jcbx_nuevocli.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbx_nuevocliActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
        jPanel5.setLayout(jPanel5Layout);
        jPanel5Layout.setHorizontalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel5Layout.createSequentialGroup()
                        .addGap(81, 81, 81)
                        .addComponent(jrb_bclave)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jrb_bdescrip)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jrb_direccion)
                        .addGap(38, 38, 38)
                        .addComponent(jLabel22)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_busqueda, javax.swing.GroupLayout.PREFERRED_SIZE, 173, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jbtn_buscar, javax.swing.GroupLayout.PREFERRED_SIZE, 102, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel24)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jlbl_textobuscado, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jLabel25)
                        .addGap(18, 18, 18)
                        .addComponent(jlbl_cantidadregistros, javax.swing.GroupLayout.PREFERRED_SIZE, 27, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(8, 8, 8)
                        .addComponent(jLabel26))
                    .addGroup(jPanel5Layout.createSequentialGroup()
                        .addComponent(jLabel44, javax.swing.GroupLayout.PREFERRED_SIZE, 59, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_idmodi, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jbtn_actualizar)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jcbx_nuevocli)))
                .addContainerGap())
            .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(jPanel5Layout.createSequentialGroup()
                    .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 914, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(12, Short.MAX_VALUE)))
        );
        jPanel5Layout.setVerticalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(jLabel22)
                        .addComponent(jtf_busqueda, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jbtn_buscar)
                        .addComponent(jlbl_textobuscado)
                        .addComponent(jlbl_cantidadregistros)
                        .addComponent(jLabel25)
                        .addComponent(jLabel24)
                        .addComponent(jLabel26))
                    .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                        .addComponent(jrb_bclave)
                        .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jrb_bdescrip, javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(jrb_direccion))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 185, Short.MAX_VALUE)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel44)
                    .addComponent(jtf_idmodi, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jbtn_actualizar)
                    .addComponent(jcbx_nuevocli))
                .addContainerGap())
            .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(jPanel5Layout.createSequentialGroup()
                    .addGap(31, 31, 31)
                    .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 180, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(35, Short.MAX_VALUE)))
        );

        jPanel7.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jPanel7.border.title"))); // NOI18N
        jPanel7.setName("jPanel7"); // NOI18N

        jtf_cliente.setText(resourceMap.getString("jtf_cliente.text")); // NOI18N
        jtf_cliente.setName("jtf_cliente"); // NOI18N
        jtf_cliente.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_clienteActionPerformed(evt);
            }
        });

        jLabel28.setText(resourceMap.getString("jLabel28.text")); // NOI18N
        jLabel28.setName("jLabel28"); // NOI18N

        jtf_observaciones1.setName("jtf_observaciones1"); // NOI18N
        jtf_observaciones1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_observaciones1ActionPerformed(evt);
            }
        });

        jtf_idcliente1.setEditable(false);
        jtf_idcliente1.setText(resourceMap.getString("jtf_idcliente1.text")); // NOI18N
        jtf_idcliente1.setAutoscrolls(false);
        jtf_idcliente1.setName("jtf_idcliente1"); // NOI18N

        jLabel30.setText(resourceMap.getString("jLabel30.text")); // NOI18N
        jLabel30.setName("jLabel30"); // NOI18N

        jtf_dompobla1.setName("jtf_dompobla1"); // NOI18N
        jtf_dompobla1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_dompobla1ActionPerformed(evt);
            }
        });

        jtf_cp.setName("jtf_cp"); // NOI18N
        jtf_cp.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_cpActionPerformed(evt);
            }
        });

        jtf_domcalle1.setName("jtf_domcalle1"); // NOI18N
        jtf_domcalle1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_domcalle1ActionPerformed(evt);
            }
        });

        jLabel34.setText(resourceMap.getString("jLabel34.text")); // NOI18N
        jLabel34.setName("jLabel34"); // NOI18N

        jLabel35.setText(resourceMap.getString("jLabel35.text")); // NOI18N
        jLabel35.setName("jLabel35"); // NOI18N

        jLabel36.setText(resourceMap.getString("jLabel36.text")); // NOI18N
        jLabel36.setName("jLabel36"); // NOI18N

        jLabel37.setText(resourceMap.getString("jLabel37.text")); // NOI18N
        jLabel37.setName("jLabel37"); // NOI18N

        jtf_domcolonia1.setName("jtf_domcolonia1"); // NOI18N
        jtf_domcolonia1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_domcolonia1ActionPerformed(evt);
            }
        });

        jLabel38.setText(resourceMap.getString("jLabel38.text")); // NOI18N
        jLabel38.setName("jLabel38"); // NOI18N

        jtf_email2.setName("jtf_email2"); // NOI18N
        jtf_email2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_email2ActionPerformed(evt);
            }
        });

        jtf_direccion2.setName("jtf_direccion2"); // NOI18N
        jtf_direccion2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_direccion2ActionPerformed(evt);
            }
        });

        jLabel39.setText(resourceMap.getString("jLabel39.text")); // NOI18N
        jLabel39.setName("jLabel39"); // NOI18N

        jtf_rfc.setName("jtf_rfc"); // NOI18N
        jtf_rfc.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_rfcActionPerformed(evt);
            }
        });

        jLabel40.setText(resourceMap.getString("jLabel40.text")); // NOI18N
        jLabel40.setName("jLabel40"); // NOI18N

        jtf_tel.setName("jtf_tel"); // NOI18N
        jtf_tel.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_telActionPerformed(evt);
            }
        });

        jLabel41.setText(resourceMap.getString("jLabel41.text")); // NOI18N
        jLabel41.setName("jLabel41"); // NOI18N

        jLabel42.setText(resourceMap.getString("jLabel42.text")); // NOI18N
        jLabel42.setName("jLabel42"); // NOI18N

        jtf_atnventas.setName("jtf_atnventas"); // NOI18N
        jtf_atnventas.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_atnventasActionPerformed(evt);
            }
        });

        jLabel43.setText(resourceMap.getString("jLabel43.text")); // NOI18N
        jLabel43.setName("jLabel43"); // NOI18N

        jtf_atncobra.setName("jtf_atncobra"); // NOI18N
        jtf_atncobra.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_atncobraActionPerformed(evt);
            }
        });

        jbtn_guardar1.setIcon(resourceMap.getIcon("jbtn_guardar1.icon")); // NOI18N
        jbtn_guardar1.setText(resourceMap.getString("jbtn_guardar1.text")); // NOI18N
        jbtn_guardar1.setName("jbtn_guardar1"); // NOI18N
        jbtn_guardar1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_guardar1ActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
        jPanel7.setLayout(jPanel7Layout);
        jPanel7Layout.setHorizontalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jtf_idcliente1, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel34, javax.swing.GroupLayout.PREFERRED_SIZE, 47, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_cliente, javax.swing.GroupLayout.PREFERRED_SIZE, 351, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel37)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_domcalle1, javax.swing.GroupLayout.PREFERRED_SIZE, 315, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel7Layout.createSequentialGroup()
                                .addContainerGap()
                                .addComponent(jLabel30)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_cp, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(jLabel40)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_rfc, javax.swing.GroupLayout.DEFAULT_SIZE, 91, Short.MAX_VALUE))
                            .addGroup(jPanel7Layout.createSequentialGroup()
                                .addComponent(jLabel28)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_domcolonia1, javax.swing.GroupLayout.DEFAULT_SIZE, 163, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel36)))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                                .addComponent(jLabel41)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_tel))
                            .addComponent(jtf_dompobla1, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 291, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                                .addComponent(jLabel38)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_email2, javax.swing.GroupLayout.PREFERRED_SIZE, 265, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(59, 59, 59))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                                .addComponent(jLabel39)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_direccion2, javax.swing.GroupLayout.PREFERRED_SIZE, 265, javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel35)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jtf_observaciones1, javax.swing.GroupLayout.PREFERRED_SIZE, 565, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(61, 61, 61)
                        .addComponent(jbtn_guardar1))
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addComponent(jLabel42)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_atnventas, javax.swing.GroupLayout.DEFAULT_SIZE, 176, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jLabel43)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jtf_atncobra, javax.swing.GroupLayout.PREFERRED_SIZE, 265, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(332, 332, 332)))
                .addContainerGap())
        );
        jPanel7Layout.setVerticalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jtf_idcliente1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel34)
                    .addComponent(jtf_cliente, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel37)
                    .addComponent(jtf_domcalle1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel28)
                    .addComponent(jtf_domcolonia1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel36)
                    .addComponent(jtf_dompobla1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jtf_email2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel38))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel39)
                    .addComponent(jtf_direccion2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel30)
                    .addComponent(jtf_cp, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel40)
                    .addComponent(jtf_rfc, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jtf_tel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel41))
                .addGap(18, 18, 18)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jtf_atnventas, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel42)
                    .addComponent(jLabel43)
                    .addComponent(jtf_atncobra, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(4, 4, 4)
                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel35)
                    .addComponent(jtf_observaciones1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jbtn_guardar1))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jPanel5, javax.swing.GroupLayout.Alignment.LEADING, 0, 942, Short.MAX_VALUE)
                    .addComponent(jPanel7, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(84, Short.MAX_VALUE))
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel1.TabConstraints.tabTitle"), jPanel1); // NOI18N

        jPanel8.setName("jPanel8"); // NOI18N

        jPanel10.setName("jPanel10"); // NOI18N

        jScrollPane6.setName("jScrollPane6"); // NOI18N

        jep_articuloimagen1.setContentType(resourceMap.getString("jep_articuloimagen1.contentType")); // NOI18N
        jep_articuloimagen1.setName("jep_articuloimagen1"); // NOI18N
        jScrollPane6.setViewportView(jep_articuloimagen1);

        jLabel19.setText(resourceMap.getString("jLabel19.text")); // NOI18N
        jLabel19.setName("jLabel19"); // NOI18N

        jtf_surtir.setText(resourceMap.getString("jtf_surtir.text")); // NOI18N
        jtf_surtir.setName("jtf_surtir"); // NOI18N
        jtf_surtir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_surtirActionPerformed(evt);
            }
        });

        jLabel27.setText(resourceMap.getString("jLabel27.text")); // NOI18N
        jLabel27.setName("jLabel27"); // NOI18N

        jtf_codigosurtir.setEditable(false);
        jtf_codigosurtir.setText(resourceMap.getString("jtf_codigosurtir.text")); // NOI18N
        jtf_codigosurtir.setToolTipText(resourceMap.getString("jtf_codigosurtir.toolTipText")); // NOI18N
        jtf_codigosurtir.setName("jtf_codigosurtir"); // NOI18N

        jbtn_surtir.setIcon(resourceMap.getIcon("jbtn_surtir.icon")); // NOI18N
        jbtn_surtir.setText(resourceMap.getString("jbtn_surtir.text")); // NOI18N
        jbtn_surtir.setToolTipText(resourceMap.getString("jbtn_surtir.toolTipText")); // NOI18N
        jbtn_surtir.setName("jbtn_surtir"); // NOI18N
        jbtn_surtir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_surtirActionPerformed(evt);
            }
        });

        jLabel29.setFont(resourceMap.getFont("jLabel29.font")); // NOI18N
        jLabel29.setText(resourceMap.getString("jLabel29.text")); // NOI18N
        jLabel29.setName("jLabel29"); // NOI18N

        jtf_totalpiezas1.setEditable(false);
        jtf_totalpiezas1.setFont(resourceMap.getFont("jtf_totalpiezas1.font")); // NOI18N
        jtf_totalpiezas1.setText(resourceMap.getString("jtf_totalpiezas1.text")); // NOI18N
        jtf_totalpiezas1.setName("jtf_totalpiezas1"); // NOI18N

        jLabel31.setFont(resourceMap.getFont("jLabel31.font")); // NOI18N
        jLabel31.setText(resourceMap.getString("jLabel31.text")); // NOI18N
        jLabel31.setName("jLabel31"); // NOI18N

        jtf_doctototal1.setEditable(false);
        jtf_doctototal1.setFont(resourceMap.getFont("jtf_doctototal1.font")); // NOI18N
        jtf_doctototal1.setText(resourceMap.getString("jtf_doctototal1.text")); // NOI18N
        jtf_doctototal1.setName("jtf_doctototal1"); // NOI18N

        javax.swing.GroupLayout jPanel10Layout = new javax.swing.GroupLayout(jPanel10);
        jPanel10.setLayout(jPanel10Layout);
        jPanel10Layout.setHorizontalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel10Layout.createSequentialGroup()
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel10Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel10Layout.createSequentialGroup()
                                .addComponent(jLabel19)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_surtir, javax.swing.GroupLayout.PREFERRED_SIZE, 41, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel27)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_codigosurtir, javax.swing.GroupLayout.PREFERRED_SIZE, 192, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(jPanel10Layout.createSequentialGroup()
                                .addComponent(jbtn_surtir)
                                .addGap(10, 10, 10)
                                .addComponent(jLabel29)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_totalpiezas1, javax.swing.GroupLayout.DEFAULT_SIZE, 152, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jLabel31)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_doctototal1, javax.swing.GroupLayout.PREFERRED_SIZE, 202, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(12, 12, 12))))
                    .addComponent(jScrollPane6, javax.swing.GroupLayout.PREFERRED_SIZE, 552, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );
        jPanel10Layout.setVerticalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel10Layout.createSequentialGroup()
                .addComponent(jScrollPane6, javax.swing.GroupLayout.DEFAULT_SIZE, 474, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel19)
                    .addComponent(jtf_surtir, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel27)
                    .addComponent(jtf_codigosurtir, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel29, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jtf_totalpiezas1, javax.swing.GroupLayout.PREFERRED_SIZE, 31, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jtf_doctototal1, javax.swing.GroupLayout.PREFERRED_SIZE, 29, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel31)
                    .addComponent(jbtn_surtir))
                .addContainerGap())
        );

        jPanel11.setName("jPanel11"); // NOI18N

        jScrollPane5.setName("jScrollPane5"); // NOI18N

        jtb_almacen_control.setModel(this.jtable_modelo_almacen);
        jtb_almacen_control.setName("jtb_almacen_control"); // NOI18N
        jtb_almacen_control.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jtb_almacen_controlMouseClicked(evt);
                if(evt.getClickCount() >= 1)
                {
                    dioclickartialma(evt);
                    //System.out.println(" double click" );

                }
                if(evt.getClickCount() >= 2)
                {
                    dioclickartialmafoto(evt);
                    //System.out.println(" double click" );

                }
            }
        });
        jScrollPane5.setViewportView(jtb_almacen_control);

        buttonGroup3.add(jrb_bclave1);
        jrb_bclave1.setText(resourceMap.getString("jrb_bclave1.text")); // NOI18N
        jrb_bclave1.setToolTipText(resourceMap.getString("jrb_bclave1.toolTipText")); // NOI18N
        jrb_bclave1.setActionCommand(resourceMap.getString("jrb_bclave1.actionCommand")); // NOI18N
        jrb_bclave1.setName("jrb_bclave1"); // NOI18N
        jrb_bclave1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_bclave1ActionPerformed(evt);
            }
        });

        buttonGroup3.add(jrb_bitem);
        jrb_bitem.setText(resourceMap.getString("jrb_bitem.text")); // NOI18N
        jrb_bitem.setToolTipText(resourceMap.getString("jrb_bitem.toolTipText")); // NOI18N
        jrb_bitem.setActionCommand(resourceMap.getString("jrb_bitem.actionCommand")); // NOI18N
        jrb_bitem.setName("jrb_bitem"); // NOI18N
        jrb_bitem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_bitemActionPerformed(evt);
            }
        });

        buttonGroup3.add(jrb_bdescrip1);
        jrb_bdescrip1.setText(resourceMap.getString("jrb_bdescrip1.text")); // NOI18N
        jrb_bdescrip1.setToolTipText(resourceMap.getString("jrb_bdescrip1.toolTipText")); // NOI18N
        jrb_bdescrip1.setActionCommand(resourceMap.getString("jrb_bdescrip1.actionCommand")); // NOI18N
        jrb_bdescrip1.setName("jrb_bdescrip1"); // NOI18N
        jrb_bdescrip1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jrb_bdescrip1ActionPerformed(evt);
            }
        });

        jtf_busqueda1.setToolTipText(resourceMap.getString("jtf_busqueda1.toolTipText")); // NOI18N
        jtf_busqueda1.setName("jtf_busqueda1"); // NOI18N
        jtf_busqueda1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_busqueda1ActionPerformed(evt);
            }
        });

        jLabel32.setText(resourceMap.getString("jLabel32.text")); // NOI18N
        jLabel32.setName("jLabel32"); // NOI18N

        jcbx_linea.setName("jcbx_linea"); // NOI18N
        jcbx_linea.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbx_lineaActionPerformed(evt);
            }
        });

        jbtn_buscar1.setIcon(resourceMap.getIcon("jbtn_buscar1.icon")); // NOI18N
        jbtn_buscar1.setText(resourceMap.getString("jbtn_buscar1.text")); // NOI18N
        jbtn_buscar1.setName("jbtn_buscar1"); // NOI18N
        jbtn_buscar1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_buscar1ActionPerformed(evt);
            }
        });

        jtf_filaactual.setEditable(false);
        jtf_filaactual.setText(resourceMap.getString("jtf_filaactual.text")); // NOI18N
        jtf_filaactual.setName("jtf_filaactual"); // NOI18N
        jtf_filaactual.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtf_filaactualActionPerformed(evt);
            }
        });

        jbtn_anterior.setIcon(resourceMap.getIcon("jbtn_anterior.icon")); // NOI18N
        jbtn_anterior.setName("jbtn_anterior"); // NOI18N
        jbtn_anterior.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_anteriorActionPerformed(evt);
            }
        });

        jbtn_siguiente.setIcon(resourceMap.getIcon("jbtn_siguiente.icon")); // NOI18N
        jbtn_siguiente.setText(resourceMap.getString("jbtn_siguiente.text")); // NOI18N
        jbtn_siguiente.setName("jbtn_siguiente"); // NOI18N
        jbtn_siguiente.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_siguienteActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel11Layout = new javax.swing.GroupLayout(jPanel11);
        jPanel11.setLayout(jPanel11Layout);
        jPanel11Layout.setHorizontalGroup(
            jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jScrollPane5, 0, 0, Short.MAX_VALUE)
            .addGroup(jPanel11Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel11Layout.createSequentialGroup()
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jrb_bitem)
                            .addComponent(jrb_bclave1))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(jPanel11Layout.createSequentialGroup()
                                .addComponent(jrb_bdescrip1)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(jtf_busqueda1, javax.swing.GroupLayout.PREFERRED_SIZE, 135, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jbtn_buscar1, javax.swing.GroupLayout.PREFERRED_SIZE, 98, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(jPanel11Layout.createSequentialGroup()
                                .addComponent(jLabel32)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jcbx_linea, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addGroup(jPanel11Layout.createSequentialGroup()
                        .addComponent(jtf_filaactual, javax.swing.GroupLayout.PREFERRED_SIZE, 27, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(26, 26, 26)
                        .addComponent(jbtn_anterior, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jbtn_siguiente, javax.swing.GroupLayout.PREFERRED_SIZE, 33, javax.swing.GroupLayout.PREFERRED_SIZE))))
        );
        jPanel11Layout.setVerticalGroup(
            jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel11Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jrb_bclave1)
                    .addComponent(jrb_bdescrip1)
                    .addComponent(jtf_busqueda1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jbtn_buscar1))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jrb_bitem)
                    .addComponent(jcbx_linea, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel32))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 440, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 7, Short.MAX_VALUE)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jbtn_anterior)
                    .addComponent(jtf_filaactual, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jbtn_siguiente))
                .addContainerGap())
        );

        javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);
        jPanel8.setLayout(jPanel8Layout);
        jPanel8Layout.setHorizontalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel8Layout.createSequentialGroup()
                .addComponent(jPanel11, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel8Layout.setVerticalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel8Layout.createSequentialGroup()
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel11, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel8.TabConstraints.tabTitle"), jPanel8); // NOI18N

        jPanel6.setName("jPanel6"); // NOI18N

        jScrollPane7.setName("jScrollPane7"); // NOI18N

        jtb_almacen_control1.setModel(this.jtable_modelo_almacenexterno);
        jtb_almacen_control1.setName("jtb_almacen_control1"); // NOI18N
        jScrollPane7.setViewportView(jtb_almacen_control1);

        jbtn_ajustaexistencia.setIcon(resourceMap.getIcon("jbtn_ajustaexistencia.icon")); // NOI18N
        jbtn_ajustaexistencia.setText(resourceMap.getString("jbtn_ajustaexistencia.text")); // NOI18N
        jbtn_ajustaexistencia.setName("jbtn_ajustaexistencia"); // NOI18N
        jbtn_ajustaexistencia.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtn_ajustaexistenciaActionPerformed(evt);
            }
        });

        jScrollPane8.setName("jScrollPane8"); // NOI18N

        jtb_almacen_control2.setModel(this.jtable_modelo_almacenexternodif);
        jtb_almacen_control2.setName("jtb_almacen_control2"); // NOI18N
        jScrollPane8.setViewportView(jtb_almacen_control2);

        javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);
        jPanel6.setLayout(jPanel6Layout);
        jPanel6Layout.setHorizontalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addGap(31, 31, 31)
                        .addComponent(jbtn_ajustaexistencia))
                    .addGroup(jPanel6Layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 478, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 436, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)))
                .addContainerGap(14, javax.swing.GroupLayout.PREFERRED_SIZE))
        );
        jPanel6Layout.setVerticalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addGap(27, 27, 27)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 466, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 466, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addComponent(jbtn_ajustaexistencia)
                .addContainerGap(26, Short.MAX_VALUE))
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel6.TabConstraints.tabTitle"), jPanel6); // NOI18N

        jMenuBar1.setName("jMenuBar1"); // NOI18N

        jMenu1.setText(resourceMap.getString("jMenu1.text")); // NOI18N
        jMenu1.setName("jMenu1"); // NOI18N

        jmni_verificadorprecio.setText(resourceMap.getString("jmni_verificadorprecio.text")); // NOI18N
        jmni_verificadorprecio.setName("jmni_verificadorprecio"); // NOI18N
        jmni_verificadorprecio.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_verificadorprecioActionPerformed(evt);
            }
        });
        jMenu1.add(jmni_verificadorprecio);

        jmni_salir.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.ALT_MASK));
        jmni_salir.setIcon(resourceMap.getIcon("jmni_salir.icon")); // NOI18N
        jmni_salir.setText(resourceMap.getString("jmni_salir.text")); // NOI18N
        jmni_salir.setName("jmni_salir"); // NOI18N
        jmni_salir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_salirActionPerformed(evt);
            }
        });
        jMenu1.add(jmni_salir);

        jMenuBar1.add(jMenu1);

        jMenu2.setText(resourceMap.getString("jMenu2.text")); // NOI18N
        jMenu2.setName("jMenu2"); // NOI18N

        jmni_escape.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_ESCAPE, 0));
        jmni_escape.setText(resourceMap.getString("jmni_escape.text")); // NOI18N
        jmni_escape.setName("jmni_escape"); // NOI18N
        jmni_escape.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_escapeActionPerformed(evt);
            }
        });
        jMenu2.add(jmni_escape);

        jmni_buscar.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_B, java.awt.event.InputEvent.ALT_MASK));
        jmni_buscar.setText(resourceMap.getString("jmni_buscar.text")); // NOI18N
        jmni_buscar.setName("jmni_buscar"); // NOI18N
        jmni_buscar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_buscarActionPerformed(evt);
            }
        });
        jMenu2.add(jmni_buscar);

        jmni_guardar.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F7, 0));
        jmni_guardar.setText(resourceMap.getString("jmni_guardar.text")); // NOI18N
        jmni_guardar.setName("jmni_guardar"); // NOI18N
        jmni_guardar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_guardarActionPerformed(evt);
            }
        });
        jMenu2.add(jmni_guardar);

        jMenuItem1.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_DOWN, 0));
        jMenuItem1.setIcon(resourceMap.getIcon("jMenuItem1.icon")); // NOI18N
        jMenuItem1.setText(resourceMap.getString("jMenuItem1.text")); // NOI18N
        jMenuItem1.setName("jMenuItem1"); // NOI18N
        jMenuItem1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jMenuItem1ActionPerformed(evt);
            }
        });
        jMenu2.add(jMenuItem1);

        jmni_anterior.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_UP, 0));
        jmni_anterior.setIcon(resourceMap.getIcon("jmni_anterior.icon")); // NOI18N
        jmni_anterior.setText(resourceMap.getString("jmni_anterior.text")); // NOI18N
        jmni_anterior.setName("jmni_anterior"); // NOI18N
        jmni_anterior.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_anteriorActionPerformed(evt);
            }
        });
        jMenu2.add(jmni_anterior);

        jmni_importar.setText(resourceMap.getString("jmni_importar.text")); // NOI18N
        jmni_importar.setName("jmni_importar"); // NOI18N
        jmni_importar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jmni_importarActionPerformed(evt);
            }
        });
        jMenu2.add(jmni_importar);

        jMenuBar1.add(jMenu2);

        jMenu3.setText(resourceMap.getString("jMenu3.text")); // NOI18N
        jMenu3.setName("jMenu3"); // NOI18N
        jMenuBar1.add(jMenu3);

        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 949, javax.swing.GroupLayout.PREFERRED_SIZE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addComponent(jTabbedPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 590, Short.MAX_VALUE)
                .addContainerGap())
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void jmni_salirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_salirActionPerformed
        // TODO add your handling code here:
        String mensaje="";
        if (this.jtable_modelo_doctomovidet.getRowCount()>0)
        {
            mensaje="<html><h2>Existen Datos sin Guardar, Desea Salir?</h2></html>";
        }
        else
        {
            mensaje=" Desea Salir?";
        }
         if(JOptionPane.showConfirmDialog(null, mensaje)==0)
            {
                 this.dispose();
            }
    }//GEN-LAST:event_jmni_salirActionPerformed

    private void jtf_observacionesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_observacionesActionPerformed
        // TODO add your handling code here:
        this.jtf_canpzaingresa.requestFocus();
}//GEN-LAST:event_jtf_observacionesActionPerformed

    private void jcmbx_almacenesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcmbx_almacenesActionPerformed
        // TODO add your handling code here:
        this.jtf_doctoreferencia.requestFocus();
}//GEN-LAST:event_jcmbx_almacenesActionPerformed

    private void jtf_doctoreferenciaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_doctoreferenciaActionPerformed
        // TODO add your handling code here:
        this.jtf_idcliente.requestFocus();
}//GEN-LAST:event_jtf_doctoreferenciaActionPerformed

    private void jtf_canpzaingresaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_canpzaingresaActionPerformed
        // TODO add your handling code here:
        this.jtf_idarticulo.requestFocus();
}//GEN-LAST:event_jtf_canpzaingresaActionPerformed

    private void jtf_idarticuloActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_idarticuloActionPerformed
        // TODO add your handling code here:
        this.jtf_idarticuloobserva.requestFocus();

}//GEN-LAST:event_jtf_idarticuloActionPerformed

    private void jbtn_buscaridinsuActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_buscaridinsuActionPerformed
        // TODO add your handling code here:
        if(this.jtf_idarticulo.getText().length()>0)
            {
                    int finddet=this.pedido_detalleupdate(this.jtf_idarticulo.getText().trim().toUpperCase(),this.jtf_canpzaingresa.getText().trim());
                    System.out.println("si encontro:"+finddet);
                    if (finddet==0)
                            {
                                this.carga_datos_catalogo(1, 1, this.jtf_idarticulo.getText().trim().toUpperCase(), 0,this.jtf_canpzaingresa.getText().trim(),this.jtf_idarticuloobserva.getText().toUpperCase().replace(",", "_").replace(".", "")+".");
                            }
            }
}//GEN-LAST:event_jbtn_buscaridinsuActionPerformed

    private void jbtn_importarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_importarActionPerformed
        // TODO add your handling code here:
        if(JOptionPane.showConfirmDialog(null, "Desea Importar Estos Articulos?")==0) {
            String arreglo_importa[]=this.jta_archivo.getText().split("\n");
            String arreglo_codigo[]=null;
            System.out.println("Estos tiene archivo:"+arreglo_importa.length);
            for (int i=0;i<arreglo_importa.length;i++) {
                arreglo_codigo=arreglo_importa[i].split("\t");
                this.jtf_idarticulo.setText(arreglo_codigo[0]);
                this.jtf_canpzaingresa.setText(arreglo_codigo[1]);
                this.jbtn_buscaridinsuActionPerformed(evt);
            }
            this.jtf_canpzaingresa.setText("0");
            this.jtf_idarticulo.setText("");
            this.jtf_idarticulo.requestFocus();
            this.jta_archivo.setText("");
        }
}//GEN-LAST:event_jbtn_importarActionPerformed

    private void jbtn_guardarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_guardarActionPerformed
        // TODO add your handling code here:
        String cadenafilas="",punto="",cliente=this.jtf_idcliente.getText().toString();
        float cantidad=0,totalpiezas=0;
        int nobjetotabla=this.jtable_modelo_doctomovidet.getRowCount();
        int fi=0,controlfolio=0,error=0,idclientesele=1;
        for(fi=0;fi<nobjetotabla;fi++) {
            try{
                cantidad = Float.valueOf(this.jtable_modelo_doctomovidet.getValueAt(fi, 4).toString()).floatValue();
                totalpiezas+=cantidad;
            }catch (NumberFormatException nfe) {
                cantidad=0;
                error=1;
            }
            // System.out.println("cachar error"+cadenafilas);
            if (cantidad > 0) {
                cadenafilas+=""+this.jtable_modelo_doctomovidet.getValueAt(fi, 4).toString()+":"+this.jtable_modelo_doctomovidet.getValueAt(fi, 0).toString()+":"+this.jtable_modelo_doctomovidet.getValueAt(fi, 4)+""+"\n";
            }
        }//fin del for
        if ( (totalpiezas > 0) && (error==0) && (idclientesele>0)) {
            if(JOptionPane.showConfirmDialog(null, "<html>Documento de Cliente:<b><h3>"+cliente+"</h3></b> sera Guardado. Estan correcto sus Datos?</html>")==0) {
                //for(int i = 0 ;i < nobjetotabla; i++) {
                 //   punto=jtable_modelo_doctomovidet.getValueAt(i, 6).toString().replace(".", "")+".";
                  //  jtable_modelo_doctomovidet.setValueAt(punto, i,6);
                //}
                String arreglo_alma[]=this.jcmbx_almacenes.getSelectedItem().toString().split(":");
                String arreglo_idcliente=this.jtf_idcliente.getText();
                java.util.Vector arreglodearticulos=this.jtable_modelo_doctomovidet.getDataVector();
                String articulos_papostgresql=arreglodearticulos.toString();
                articulos_papostgresql=articulos_papostgresql.replace('[','{');
                articulos_papostgresql=articulos_papostgresql.replace(']','}');
                articulos_papostgresql=articulos_papostgresql.replace("null",".");
                String texto="select * from x1distribucion_terminados_ventas_agregar(1,'"+this.fechaamericana(this.jdc_fechadocto.getDate())+"','"+this.jtf_doctoreferencia.getText().trim().toUpperCase()+"','"+arreglo_alma[0]+"','"+arreglo_idcliente+"','1','"+variables_global.getLogin()+"','"+this.jtf_observaciones.getText().trim().toUpperCase().replace(",", "")+"','"+articulos_papostgresql+"','"+this.jtf_descuento.getText().trim()+"','"+this.jtf_impuesto.getText().trim()+"')";
                System.out.println(texto);
                try {
                    rs=x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
                    while (rs.next()) {
                        controlfolio=rs.getInt(1);
                        if (rs.getInt(1) > 0) {
                            JOptionPane.showMessageDialog(null,"Folio Venta:"+controlfolio+" Correcto, Gracias", "Sistema Integral(Venta Articulos) : Confirmacion",1);
                             while(jtable_modelo_doctomovidet.getRowCount()>0)jtable_modelo_doctomovidet.removeRow(0);
                             this.jtf_doctoreferencia.setText("");
                             this.jtf_idcliente.setText("0");
                             this.jtf_observaciones.setText("");

                             this.jtf_doctoreferencia.requestFocus();
                                //JFrame mainFrame = Sie_invdisApp.getApplication().getMainFrame();
                                com_distri_folios_detalle fdd=new com_distri_folios_detalle(String.valueOf(controlfolio));
                                fdd.pack();
                                fdd.setVisible(true);
                        } else {
                            JOptionPane.showMessageDialog(null," Error Verifique sus Cantidades", "Sistema Integral(requisicion Insumos) : Error",1);
                        }
                    }
                } catch(Exception e) {
                    System.out.println(e.getMessage());
                    JOptionPane.showMessageDialog(null," Folio Venta Incorrecto ", "Sistema Integral(Venta Articulos) : Error",1);
                }
            }//fin del if qu confirmo guardar diferencia
        } else {
            JOptionPane.showMessageDialog(null,"por Favor Verifique que Las Cantidades Sean Numericas u Seleccione un cliente o Tienda");
        }

    }//GEN-LAST:event_jbtn_guardarActionPerformed



    private void jmni_escapeActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_escapeActionPerformed
        // TODO add your handling code here:
        this.jmni_salirActionPerformed(evt);
    }//GEN-LAST:event_jmni_escapeActionPerformed

    private void jmni_guardarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_guardarActionPerformed
        // TODO add your handling code here:
 switch (indexactual)
             {
                case 0:
                    this.jbtn_guardarActionPerformed(evt);
                break;
                case 1:
                    this.jbtn_guardar1ActionPerformed(evt);
                break;
            }
       
    }//GEN-LAST:event_jmni_guardarActionPerformed

    private void jmni_buscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_buscarActionPerformed
        // TODO add your handling code here:
        this.jbtn_buscaridinsuActionPerformed(evt);
    }//GEN-LAST:event_jmni_buscarActionPerformed

    private void jrbtn_precio1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrbtn_precio1ActionPerformed
        // TODO add your handling code here:
        listap=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrbtn_precio1ActionPerformed

    private void jrbtn_preciomActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrbtn_preciomActionPerformed
        // TODO add your handling code here:
        listap=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrbtn_preciomActionPerformed

    private void jtf_domcalleActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_domcalleActionPerformed
        // TODO add your handling code here:
        this.jtf_domcolonia.requestFocus();
}//GEN-LAST:event_jtf_domcalleActionPerformed

    private void jtf_domcoloniaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_domcoloniaActionPerformed
        // TODO add your handling code here:
       // this.jtf_dompobla.requestFocus();
}//GEN-LAST:event_jtf_domcoloniaActionPerformed

    private void jtf_domcodActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_domcodActionPerformed
        // TODO add your handling code here:
        //this.jtf_domtelefono.requestFocus();
}//GEN-LAST:event_jtf_domcodActionPerformed

    private void jtf_emailActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_emailActionPerformed
        // TODO add your handling code here:
        //this.jtf_empfoto.requestFocus();
}//GEN-LAST:event_jtf_emailActionPerformed

    private void jtf_email1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_email1ActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_jtf_email1ActionPerformed

    private void jrb_direccionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_direccionActionPerformed
        // TODO add your handling code here:
        opcioncatalogo=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_direccionActionPerformed

    private void jrb_bdescripActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_bdescripActionPerformed
        // TODO add your handling code here:
        opcioncatalogo=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_bdescripActionPerformed

    private void jrb_bclaveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_bclaveActionPerformed
        // TODO add your handling code here:
        opcioncatalogo=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_bclaveActionPerformed

    private void jtf_busquedaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_busquedaActionPerformed
        // TODO add your handling code here:
        this.jbtn_buscarActionPerformed(evt);
}//GEN-LAST:event_jtf_busquedaActionPerformed

    private void jbtn_buscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_buscarActionPerformed
        // TODO add your handling code here:
        // this.jtf_busqueda.getText();
        if(JOptionPane.showConfirmDialog(null, "Estan Correctos sus Datos?")==0) {
            this.carga_datos_clientes(opcioncatalogo, this.jtf_busqueda.getText().trim().toUpperCase());
        } else {
            this.jtf_busqueda.requestFocus();
        }
    }//GEN-LAST:event_jbtn_buscarActionPerformed

    private void jtf_observaciones1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_observaciones1ActionPerformed
        // TODO add your handling code here:
        this.jbtn_guardar1.requestFocus();
    }//GEN-LAST:event_jtf_observaciones1ActionPerformed

    private void jtf_dompobla1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_dompobla1ActionPerformed
        // TODO add your handling code here:
        this.jtf_email2.requestFocus();
    }//GEN-LAST:event_jtf_dompobla1ActionPerformed

    private void jtf_cpActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_cpActionPerformed
        // TODO add your handling code here:
        this.jtf_rfc.requestFocus();
}//GEN-LAST:event_jtf_cpActionPerformed

    private void jtf_domcalle1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_domcalle1ActionPerformed
        // TODO add your handling code here:
        this.jtf_domcolonia1.requestFocus();
    }//GEN-LAST:event_jtf_domcalle1ActionPerformed

    private void jtf_domcolonia1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_domcolonia1ActionPerformed
        // TODO add your handling code here:
        this.jtf_dompobla1.requestFocus();
    }//GEN-LAST:event_jtf_domcolonia1ActionPerformed

    private void jtf_email2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_email2ActionPerformed
        // TODO add your handling code here:
        this.jtf_cp.requestFocus();
    }//GEN-LAST:event_jtf_email2ActionPerformed

    private void jtf_direccion2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_direccion2ActionPerformed
        // TODO add your handling code here:
        this.jtf_atnventas.requestFocus();
}//GEN-LAST:event_jtf_direccion2ActionPerformed

    private void jtf_rfcActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_rfcActionPerformed
        // TODO add your handling code here:
        this.jtf_tel.requestFocus();
}//GEN-LAST:event_jtf_rfcActionPerformed

    private void jtf_telActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_telActionPerformed
        // TODO add your handling code here:
        this.jtf_direccion2.requestFocus();
}//GEN-LAST:event_jtf_telActionPerformed

    private void jtf_atnventasActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_atnventasActionPerformed
        // TODO add your handling code here:
        this.jtf_atncobra.requestFocus();
}//GEN-LAST:event_jtf_atnventasActionPerformed

    private void jtf_atncobraActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_atncobraActionPerformed
        // TODO add your handling code here:
        this.jtf_observaciones1.requestFocus();
}//GEN-LAST:event_jtf_atncobraActionPerformed

    private void jbtn_guardar1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_guardar1ActionPerformed
        // TODO add your handling code here:
        int cliente=Integer.valueOf(this.jtf_idcliente1.getText().toString()),opcion=0;

          if (this.jtf_idcliente1.getText().toString().length()>0)
          {
                if(JOptionPane.showConfirmDialog(null, "Datos de Cliente Correctos?")==0)
                    {
                        if (cliente>0)
                                {
                                    this.guarda_cliente(2);
                                }
                        else
                                {
                                    this.guarda_cliente(1);
                                }
                    }
        }
        else
            {
                JOptionPane.showMessageDialog(null,"Favor de Verificar Viaje,Proveedor etc", "Sistema Integral(Agregar Produccion) : Error",1);
            }
    }//GEN-LAST:event_jbtn_guardar1ActionPerformed

    private void jtb_insumosKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtb_insumosKeyPressed
        // TODO add your handling code here:
        System.out.println(evt.getKeyCode());
        System.out.println("Hola");
        if (evt.getKeyCode() == 10) {
            try {
                this.calcularimportes();
            } catch (Exception ex) {
                System.out.println("ERROR no ha elegido en el cuadro de texto");
            }

        }
    }//GEN-LAST:event_jtb_insumosKeyPressed

    private void jtb_insumosPropertyChange(java.beans.PropertyChangeEvent evt) {//GEN-FIRST:event_jtb_insumosPropertyChange
        // TODO add your handling code here:
         this.calcularimportes();
    }//GEN-LAST:event_jtb_insumosPropertyChange

    private void jchbx_eliminarfilaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jchbx_eliminarfilaActionPerformed
        // TODO add your handling code here:
        int fila = jtb_insumos.getSelectedRow();
        if(this.jtf_deletefila.getText().length()>0)
            {
                if(JOptionPane.showConfirmDialog(null, "Desea Eliminar Fila Seleccionada?")==0) {
                   jtable_modelo_doctomovidet.removeRow(fila);
                   this.calcularimportes();
                }
            }

    }//GEN-LAST:event_jchbx_eliminarfilaActionPerformed

    private void jrb_bclave1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_bclave1ActionPerformed
        // TODO add your handling code here:

        buscampalma=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_bclave1ActionPerformed

    private void jrb_bdescrip1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_bdescrip1ActionPerformed
        // TODO add your handling code here:
        buscampalma=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_bdescrip1ActionPerformed

    private void jtf_busqueda1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_busqueda1ActionPerformed
        // TODO add your handling code here:
        this.jbtn_buscar1ActionPerformed(evt);
}//GEN-LAST:event_jtf_busqueda1ActionPerformed

    private void jbtn_buscar1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_buscar1ActionPerformed
        // TODO add your handling code here:
        // this.jtf_busqueda.getText();

                if(JOptionPane.showConfirmDialog(null, "Estan Correctos sus Datos?")==0) {
                    this.carga_datos_catalogoarticulos_almacen( buscampalma,3,this.jtf_busqueda1.getText().toUpperCase().trim());
                } else {
                    this.jtf_busqueda.requestFocus();
                }

    }//GEN-LAST:event_jbtn_buscar1ActionPerformed

    private void jrb_bitemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jrb_bitemActionPerformed
        // TODO add your handling code here:
        buscampalma=Integer.parseInt(evt.getActionCommand().toString());
}//GEN-LAST:event_jrb_bitemActionPerformed

    private void jbtn_surtirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_surtirActionPerformed
        // TODO add your handling code here:
         if(JOptionPane.showConfirmDialog(null, "Desea Agregar:"+this.jtf_surtir.getText()+" a nota?")==0) {
                     this.jtf_canpzaingresa.setText(this.jtf_surtir.getText());
                    this.jtf_idarticulo.setText(this.jtf_codigosurtir.getText())                ;
                    this.jbtn_buscaridinsuActionPerformed(evt);
         }

}//GEN-LAST:event_jbtn_surtirActionPerformed

    private void jbtn_actualizarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_actualizarActionPerformed
        // TODO add your handling code here:
        this.carga_datos_clientesactualiza(2,this.jtf_idmodi.getText());
        this.jtf_cliente.requestFocus();
    }//GEN-LAST:event_jbtn_actualizarActionPerformed

    private void jcbx_lineaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_lineaActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jcbx_lineaActionPerformed

    private void jTabbedPane1StateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_jTabbedPane1StateChanged
        // TODO add your handling code here:
         indexactual=this.jTabbedPane1.getSelectedIndex();
      switch (indexactual) 
            {
                case 0:
                      this.jtf_idarticulo.requestFocus();
                break;
                case 1:
                      this.jtf_busqueda.requestFocus();
                break;
                case 2:
                    this.jtf_busqueda1.requestFocus();
                break;
                case 3:
                if(JOptionPane.showConfirmDialog(null, "Desea Actualizar Su Existencia Local:?")==0)
                    {
                        this.carga_datos_catalogoarticulos_actualizar(1, 3, "");
                        x.estableceConexionexterna();
                        this.verexistenciasexternas();
                        x.cierraConexionexterna(variables_global.getconexiongralext());
                    }
                break;
            }

    }//GEN-LAST:event_jTabbedPane1StateChanged

    private void jtf_surtirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_surtirActionPerformed
        // TODO add your handling code here:
        this.jbtn_surtirActionPerformed(evt);
    }//GEN-LAST:event_jtf_surtirActionPerformed

    private void jcbx_nuevocliActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_nuevocliActionPerformed
        // TODO add your handling code here:
        this.jtf_idcliente1.setText("0");
        this.jtf_cliente.setText("");
        this.jtf_cliente.requestFocus();

    }//GEN-LAST:event_jcbx_nuevocliActionPerformed

    private void jtf_clienteActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_clienteActionPerformed
        // TODO add your handling code here:
        this.jtf_domcalle1.requestFocus();
    }//GEN-LAST:event_jtf_clienteActionPerformed

    private void jtf_idclienteActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_idclienteActionPerformed
        // TODO add your handling code here:
        this.carga_datos_clientedocto(2, this.jtf_idcliente.getText().toString().trim());
    }//GEN-LAST:event_jtf_idclienteActionPerformed

    private void jtf_filaactualActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_filaactualActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jtf_filaactualActionPerformed

    private void jbtn_siguienteActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_siguienteActionPerformed
        // TODO add your handling code here:
        int filatexto=Integer.valueOf(this.jtf_filaactual.getText().toString())+1;
          this.jtb_almacen_control.changeSelection(filatexto, 0, true, false);
          this.jtf_filaactual.setText(String.valueOf(filatexto));
        String idcadena=this.jtable_modelo_almacen.getValueAt(filatexto, 0).toString();
        this.jep_articuloimagen1.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+idcadena+".JPG\" width=\"600\" height=\"500\" border=\"0\" alt=\"Foto Articulo\"></img>");
        this.jtf_codigosurtir.setText(idcadena);
        this.jtf_surtir.setText(this.jtable_modelo_almacen.getValueAt(filatexto, 5).toString());
}//GEN-LAST:event_jbtn_siguienteActionPerformed

    private void jMenuItem1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem1ActionPerformed
        // TODO add your handling code here:
        this.jbtn_siguienteActionPerformed(evt);
    }//GEN-LAST:event_jMenuItem1ActionPerformed

    private void jbtn_anteriorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_anteriorActionPerformed
        // TODO add your handling code here:
                int filatexto=Integer.valueOf(this.jtf_filaactual.getText().toString())-1;
          this.jtb_almacen_control.changeSelection(filatexto, 0, true, false);
          this.jtf_filaactual.setText(String.valueOf(filatexto));
        String idcadena=this.jtable_modelo_almacen.getValueAt(filatexto, 0).toString();
        this.jep_articuloimagen1.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+idcadena+".JPG\" width=\"600\" height=\"500\" border=\"0\" alt=\"Foto Articulo\"></img>");
        this.jtf_codigosurtir.setText(idcadena);
        this.jtf_surtir.setText(this.jtable_modelo_almacen.getValueAt(filatexto, 5).toString());
}//GEN-LAST:event_jbtn_anteriorActionPerformed

    private void jmni_anteriorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_anteriorActionPerformed
        // TODO add your handling code here:
        this.jbtn_anteriorActionPerformed(evt);
    }//GEN-LAST:event_jmni_anteriorActionPerformed

    private void jmni_importarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_importarActionPerformed
        // TODO add your handling code here:
        this.jPanel9.setVisible(true);
    }//GEN-LAST:event_jmni_importarActionPerformed

    private void jcbx_idmonedaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_idmonedaActionPerformed
        // TODO add your handling code here:
         if (controlcombocambio>0)
            {
                        String cambio[]=null;
                        cambio=this.jcbx_idmoneda.getSelectedItem().toString().split(":");
                        this.jtf_tipocambio.setText(cambio[2]);
                        this.calcularimportes();
            }
    }//GEN-LAST:event_jcbx_idmonedaActionPerformed

    private void jtf_tipocambioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_tipocambioActionPerformed
        // TODO add your handling code here:
            if(JOptionPane.showConfirmDialog(null, "Desea Actualizar cambio?")==0) {
            int retorno=0;
            DecimalFormat miformat = new DecimalFormat("############.##");
            String cambio[]=this.jcbx_idmoneda.getSelectedItem().toString().split(":");
            String texto="select * from x1distribucion_terminados_ventas_monedas_update(1,'"+cambio[0]+"','','"+this.jtf_tipocambio.getText().trim()+"','','');";
            System.out.println(texto);
            try
                {
                    rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
                    while (rs.next())
                        {
                            retorno=rs.getInt(1);
                        }
                }
                catch(Exception e)
                    {
                        System.out.println(e.getMessage());
                    }
                    if (retorno==1)
                                     {
                                                  controlcombocambio=0;
                                                  this.jcbx_idmoneda.removeAllItems();
                                                  this.jcbx_idmoneda.addItem(cambio[0]+":"+cambio[1]+":"+miformat.format(Float.valueOf(this.jtf_tipocambio.getText().trim())));
                                                  this.loadcombomonedas();
                                                  controlcombocambio=1;
                                     }
        }
        this.calcularimportes();
    }//GEN-LAST:event_jtf_tipocambioActionPerformed

    private void jmni_verificadorprecioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_verificadorprecioActionPerformed
        // TODO add your handling code here:
        articulos_sie_editar_foto fasef=new articulos_sie_editar_foto();
        fasef.pack();
        RefineryUtilities.centerFrameOnScreen(fasef);

        fasef.setVisible(true);
    }//GEN-LAST:event_jmni_verificadorprecioActionPerformed

    private void jcbx_verificadorprecioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_verificadorprecioActionPerformed
        // TODO add your handling code here:
        this.jmni_verificadorprecioActionPerformed(evt);
    }//GEN-LAST:event_jcbx_verificadorprecioActionPerformed

    private void jtf_idarticuloobservaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_idarticuloobservaActionPerformed
        // TODO add your handling code here:
        this.jbtn_buscaridinsuActionPerformed(evt);
}//GEN-LAST:event_jtf_idarticuloobservaActionPerformed

    private void jbtn_ajustaexistenciaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_ajustaexistenciaActionPerformed
        // TODO add your handling code here:
        int controlfolio=0;
        java.util.Vector arreglodearticulos=this.jtable_modelo_almacenexternodif.getDataVector();
        String articulos_papostgresql=arreglodearticulos.toString();
        articulos_papostgresql=articulos_papostgresql.replace('[','{');
        articulos_papostgresql=articulos_papostgresql.replace(']','}');
        articulos_papostgresql=articulos_papostgresql.replace("null",".");
        String texto="select * from x1distribucion_terminados_artic_mov_inve_ajustaexistencia(1,9,'"+articulos_papostgresql+"')";
        System.out.println(texto);
        try {
            rs=x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next()) {
                controlfolio=rs.getInt(1);
            }
        } catch(Exception e) {
            System.out.println(e.getMessage());
            JOptionPane.showMessageDialog(null,"Actualizacion Incorrecta ","Sistema Integral(Sincronizar) : Error",1);

        }
        if (controlfolio > 0) {
            while(jtable_modelo_almacenexterno.getRowCount()>0)jtable_modelo_almacenexterno.removeRow(0);
            while(jtable_modelo_almacenexternodif.getRowCount()>0)jtable_modelo_almacenexternodif.removeRow(0);
            JOptionPane.showMessageDialog(null,"Actualizacion Correcta!, Gracias", "Sistema Integral(Sincroniza BD) : Confirmacion",1);

        } else {
            JOptionPane.showMessageDialog(null," Error Verifique sus Cantidades", "Sistema Integral(requisicion Insumos) : Error",1);
        }
}//GEN-LAST:event_jbtn_ajustaexistenciaActionPerformed
   private void jtb_insumosMouseClicked(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
    }
    private void jt_clientesMouseClicked(java.awt.event.MouseEvent evt) {
        // TODO add your handling code here:
    }
    private String  fechaeuropea(String fecha) {
         //resibe cadena de fecha en formato americano yyyy-MM-dd
        java.util.Date fechaestaeuropa=null;
       SimpleDateFormat formateadorestaeuropa = new SimpleDateFormat("dd-MM-yyyy");
       String cadenafecha="";
        try
         {
          fechaestaeuropa = formateadoresta.parse(fecha);
         }
        catch (ParseException e)
          {
             //Error, la cadena de texto no se puede convertir en fecha.
          }
       cadenafecha= formateadorestaeuropa.format(fechaestaeuropa);
       return cadenafecha;

    }

    private String fechaamericana(Date fe) {
       SimpleDateFormat formateadorestaeuropa = new SimpleDateFormat("yyyy-MM-dd");
       String cadenafecha="";
       cadenafecha= formateadorestaeuropa.format(fe);
       return cadenafecha;
    }
    private String DiaSemana(String fe) {
       String dia = "";
       java.util.Date fecha=null;
         try
           {
             fecha = formateador.parse(fe);
           }
        catch (ParseException e)
            {
            //Error, la cadena de texto no se puede convertir en fecha.
            }
        Calendar cal= Calendar.getInstance();
        cal.setTime(fecha);
        //ojo para establecer o recetear cada parte de la fecha por separado
        //cal.set(Calendar.YEAR, fecha.getYear());
        //cal.set(Calendar.MONTH, fecha.getMonth());
        //cal.set(Calendar.DAY_OF_MONTH, fecha.getDay());
        int diaInt = cal.get(Calendar.DAY_OF_WEEK);
        switch (diaInt) {
            case 1:
                dia = "Domingo";
                break;
            case 2:
                dia = "Lunes";
                break;
            case 3:
                dia = "Martes";
                break;
            case 4:
                dia = "Miercoles";
                break;
            case 5:
                dia = "Jueves";
                break;
            case 6:
                dia = "Viernes";
                break;
            case 7:
                dia = "Sabado";
                break;

        }
        return dia;
    }
    /**
    * @param args the command line arguments
    */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new com_distri_folios_agregar().setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.ButtonGroup buttonGroup1;
    private javax.swing.ButtonGroup buttonGroup2;
    private javax.swing.ButtonGroup buttonGroup3;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel22;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel24;
    private javax.swing.JLabel jLabel25;
    private javax.swing.JLabel jLabel26;
    private javax.swing.JLabel jLabel27;
    private javax.swing.JLabel jLabel28;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel32;
    private javax.swing.JLabel jLabel33;
    private javax.swing.JLabel jLabel34;
    private javax.swing.JLabel jLabel35;
    private javax.swing.JLabel jLabel36;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel38;
    private javax.swing.JLabel jLabel39;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel41;
    private javax.swing.JLabel jLabel42;
    private javax.swing.JLabel jLabel43;
    private javax.swing.JLabel jLabel44;
    private javax.swing.JLabel jLabel45;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JMenu jMenu1;
    private javax.swing.JMenu jMenu2;
    private javax.swing.JMenu jMenu3;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JMenuItem jMenuItem1;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel10;
    private javax.swing.JPanel jPanel11;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JPanel jPanel6;
    private javax.swing.JPanel jPanel7;
    private javax.swing.JPanel jPanel8;
    private javax.swing.JPanel jPanel9;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JScrollPane jScrollPane6;
    private javax.swing.JScrollPane jScrollPane7;
    private javax.swing.JScrollPane jScrollPane8;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JButton jbtn_actualizar;
    private javax.swing.JButton jbtn_ajustaexistencia;
    private javax.swing.JButton jbtn_anterior;
    private javax.swing.JButton jbtn_buscar;
    private javax.swing.JButton jbtn_buscar1;
    private javax.swing.JButton jbtn_buscaridinsu;
    private javax.swing.JButton jbtn_guardar;
    private javax.swing.JButton jbtn_guardar1;
    private javax.swing.JButton jbtn_importar;
    private javax.swing.JButton jbtn_siguiente;
    private javax.swing.JButton jbtn_surtir;
    private javax.swing.JComboBox jcbx_idmoneda;
    private javax.swing.JComboBox jcbx_linea;
    private javax.swing.JCheckBox jcbx_nuevocli;
    private javax.swing.JCheckBox jcbx_verificadorprecio;
    private javax.swing.JCheckBox jchbx_eliminarfila;
    private javax.swing.JComboBox jcmbx_almacenes;
    private com.toedter.calendar.JDateChooser jdc_fechadocto;
    private javax.swing.JEditorPane jep_articuloimagen;
    private javax.swing.JEditorPane jep_articuloimagen1;
    private javax.swing.JLabel jlbl_cantidadregistros;
    private javax.swing.JLabel jlbl_formatoarchivo;
    private javax.swing.JLabel jlbl_monedadescribe;
    private javax.swing.JLabel jlbl_textobuscado;
    private javax.swing.JMenuItem jmni_anterior;
    private javax.swing.JMenuItem jmni_buscar;
    private javax.swing.JMenuItem jmni_escape;
    private javax.swing.JMenuItem jmni_guardar;
    private javax.swing.JMenuItem jmni_importar;
    private javax.swing.JMenuItem jmni_salir;
    private javax.swing.JMenuItem jmni_verificadorprecio;
    private javax.swing.JPanel jpn_cuerpo;
    private javax.swing.JRadioButton jrb_bclave;
    private javax.swing.JRadioButton jrb_bclave1;
    private javax.swing.JRadioButton jrb_bdescrip;
    private javax.swing.JRadioButton jrb_bdescrip1;
    private javax.swing.JRadioButton jrb_bitem;
    private javax.swing.JRadioButton jrb_direccion;
    private javax.swing.JRadioButton jrbtn_precio1;
    private javax.swing.JRadioButton jrbtn_preciom;
    private javax.swing.JTable jt_clientes;
    private javax.swing.JTextArea jta_archivo;
    private javax.swing.JTable jtb_almacen_control;
    private javax.swing.JTable jtb_almacen_control1;
    private javax.swing.JTable jtb_almacen_control2;
    private javax.swing.JTable jtb_insumos;
    private javax.swing.JTextField jtf_atncobra;
    private javax.swing.JTextField jtf_atnventas;
    private javax.swing.JTextField jtf_busqueda;
    private javax.swing.JTextField jtf_busqueda1;
    private javax.swing.JTextField jtf_canpzaingresa;
    private javax.swing.JTextField jtf_cliente;
    private javax.swing.JTextField jtf_cliobs;
    private javax.swing.JTextField jtf_codigosurtir;
    private javax.swing.JTextField jtf_conversionmoneda;
    private javax.swing.JTextField jtf_cp;
    private javax.swing.JTextField jtf_deletefila;
    private javax.swing.JTextField jtf_descuento;
    private javax.swing.JTextField jtf_direccion2;
    private javax.swing.JTextField jtf_direccionclie;
    private javax.swing.JTextField jtf_doctodesc;
    private javax.swing.JTextField jtf_doctoimp;
    private javax.swing.JTextField jtf_doctoreferencia;
    private javax.swing.JTextField jtf_doctosubtotal;
    private javax.swing.JTextField jtf_doctototal;
    private javax.swing.JTextField jtf_doctototal1;
    private javax.swing.JTextField jtf_domcalle;
    private javax.swing.JTextField jtf_domcalle1;
    private javax.swing.JTextField jtf_domcod;
    private javax.swing.JTextField jtf_domcolonia;
    private javax.swing.JTextField jtf_domcolonia1;
    private javax.swing.JTextField jtf_dompobla1;
    private javax.swing.JTextField jtf_email;
    private javax.swing.JTextField jtf_email1;
    private javax.swing.JTextField jtf_email2;
    private javax.swing.JTextField jtf_filaactual;
    private javax.swing.JTextField jtf_idarticulo;
    private javax.swing.JTextField jtf_idarticuloobserva;
    private javax.swing.JTextField jtf_idcliente;
    private javax.swing.JTextField jtf_idcliente1;
    private javax.swing.JTextField jtf_idmodi;
    private javax.swing.JTextField jtf_impuesto;
    private javax.swing.JTextField jtf_observaciones;
    private javax.swing.JTextField jtf_observaciones1;
    private javax.swing.JTextField jtf_rfc;
    private javax.swing.JTextField jtf_surtir;
    private javax.swing.JTextField jtf_tel;
    private javax.swing.JTextField jtf_tipocambio;
    private javax.swing.JTextField jtf_totalpiezas;
    private javax.swing.JTextField jtf_totalpiezas1;
    private javax.swing.JTextField jtf_ultimocodigo;
    private javax.swing.JTextField jtf_ultimodescripcion;
    // End of variables declaration//GEN-END:variables

}
